1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
|
[package]
name = "zellij"
build = "src/build.rs"
authors = ["Aram Drevekenin <aram@poor.dev>"]
description = "A terminal workspace with batteries included"
homepage = "https://zellij.dev"
include = ["src/**/*", "assets/layouts/*", "assets/config/*", "LICENSE.md", "README.md", "!**/*_test.*", "!**/tests/**/*"]
# See 'workspace.package' for concrete values
license.workspace = true
repository.workspace = true
edition.workspace = true
version.workspace = true
rust-version.workspace = true
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
# sl0p fork: the *binary* is sl0ppij, the *package* stays zellij.
#
# Renaming the package would ripple through every intra-workspace dependency
# (`zellij-client`, `zellij-server`, `zellij-utils`, `zellij-tile`), the plugin
# API and the `0.45.0+sl0p1` version trick, all for a name nobody sees. An
# explicit [[bin]] renames only what users type. Note this also disables cargo's
# target auto-discovery for the package, hence the explicit path.
[[bin]]
name = "sl0ppij"
path = "src/main.rs"
[dependencies]
zellij-client = { path = "zellij-client/", version = "0.45.0" }
zellij-server = { path = "zellij-server/", version = "0.45.0" }
zellij-utils = { workspace = true }
anyhow = { workspace = true }
clap = { workspace = true }
dialoguer = { workspace = true }
humantime = { workspace = true }
interprocess = { workspace = true }
log = { workspace = true }
miette = { workspace = true }
names = { workspace = true }
suggest = { workspace = true }
thiserror = { workspace = true }
isahc = { workspace = true }
[target.'cfg(windows)'.build-dependencies]
embed-resource = "3"
[dev-dependencies]
insta = "1.48"
ssh2 = "0.9.1"
rand = { workspace = true }
regex = { workspace = true }
vte = { workspace = true }
[workspace]
members = [
"default-plugins/compact-bar",
"default-plugins/status-bar",
"default-plugins/strider",
"default-plugins/tab-bar",
"default-plugins/fixture-plugin-for-tests",
"default-plugins/session-manager",
"default-plugins/configuration",
"default-plugins/plugin-manager",
"default-plugins/about",
"default-plugins/share",
"default-plugins/multiple-select",
"default-plugins/layout-manager",
"default-plugins/link",
"default-plugins/mobile",
"zellij-client",
"zellij-integration-tests",
"zellij-server",
"zellij-utils",
"zellij-tile",
"zellij-tile-utils",
"xtask",
".",
]
[workspace.package]
edition = "2021"
license = "MIT"
repository = "https://github.com/zellij-org/zellij"
# sl0p fork: the `-sl0pN` suffix marks a fork build so `zellij --version` is
# distinguishable from upstream. Bump the suffix for each published fork build;
# reset it to 1 when rebasing onto a new upstream version.
#
# Safe against the places VERSION is consumed:
# - it is BUILD METADATA ('+'), not a prerelease ('-'): cargo ignores build
# metadata when matching version requirements, so the intra-workspace
# `zellij-utils = "0.45.0"` deps still resolve. A `-sl0p1` prerelease does
# NOT resolve and would need every member manifest updated.
# - shared::version_number() still yields the same number as 0.45.0, so
# terminal version reporting is unaffected.
# - client/server compatibility keys off CLIENT_SERVER_CONTRACT_VERSION, not
# this, so sessions are unaffected.
# - ZELLIJ_PLUGIN_ARTIFACT_DIR is keyed by VERSION, so a bump means the wasm
# plugin cache is rebuilt once on first run.
version = "0.45.0+sl0p1"
# NOTE: When updating this, modify `channel` in `rust-toolchain.toml` accordingly
rust-version = "1.95"
[workspace.dependencies]
ansi_term = { version = "0.12.1", default-features = false }
anyhow = { version = "1.0.70", default-features = false, features = ["backtrace", "std"] }
async-trait = { version = "0.1", default-features = false }
chrono = { version = "0.4.19", default-features = false, features = ["std", "clock"] }
clap = { version = "4.6", default-features = false, features = ["std", "color", "help", "usage", "error-context", "suggestions", "wrap_help", "derive", "env"] }
crossterm = { version = "0.29", default-features = false, features = ["windows"] }
daemonize = { package = "daemonix", version = "0.1", default-features = false }
dialoguer = { version = "0.11", default-features = false, features = ["password", "completion"] }
fuzzy-matcher = { version = "0.3.7", default-features = false }
humantime = { version = "2.1.0", default-features = false }
interprocess = { version = "2.2", default-features = false, features = ["tokio"] }
isahc = { version = "1.7.2", default-features = false, features = ["http2", "text-decoding"] }
kdl = { version = "4.5.0", default-features = false, features = ["span"] }
lazy_static = { version = "1.4.0", default-features = false }
libc = { version = "0.2", default-features = false, features = ["std"] }
log = { version = "0.4.17", default-features = false }
miette = { version = "7.6", default-features = false, features = ["derive", "fancy"] }
nix = { version = "0.30", default-features = false }
notify-debouncer-full = { version = "0.5", default-features = false }
notify = { version = "8.2", default-features = false, features = ["macos_kqueue"] }
num_cpus = { version = "1.16", default-features = false }
pretty-bytes = { version = "0.2.2", default-features = false }
prost = { version = "0.12.6", default-features = false, features = ["std", "prost-derive"] }
rand = { version = "0.10.2", default-features = false, features = ["std", "std_rng", "thread_rng"] }
regex = { version = "1.5.5", default-features = false, features = ["perf", "std", "unicode-perl"] }
serde = { version = "1.0", default-features = false, features = ["derive", "std"] }
serde_json = { version = "1.0", default-features = false, features = ["std"] }
signal-hook = { version = "0.3", default-features = false, features = ["iterator"] }
strip-ansi-escapes = { version = "0.2.1", default-features = false }
strum = { version = "0.28.0", default-features = false, features = ["std"] }
strum_macros = { version = "0.28.0", default-features = false }
suggest = { version = "0.5.1", default-features = false }
tempfile = { version = "3.2.0", default-features = false }
tokio = { version = "1.40", default-features = false, features = ["fs", "rt-multi-thread", "macros", "time", "process", "signal", "io-util", "io-std", "net"] }
thiserror = { version = "2.0.18", default-features = false, features = ["std"] }
tokio-util = { version = "0.7.15" }
unicode-width = { version = "0.2.2", default-features = false }
url = { version = "2.2.2", default-features = false, features = ["serde"] }
uuid = { version = "1.4.1", default-features = false, features = ["serde", "v4", "std"] }
vte = { version = "0.15", default-features = false, features = ["std"] }
windows-sys = { version = "0.59", default-features = false }
names = { version = "0.14.0", default-features = false }
include_dir = { version = "0.7.3", default-features = false }
sha2 = { version = "0.11", default-features = false }
zellij-utils = { path = "zellij-utils/", version = "0.45.0" }
[profile.dev]
debug = "line-tables-only"
[profile.dev-opt]
inherits = "dev"
[profile.dev-opt.package."*"]
opt-level = 3
[profile.release]
lto = true
strip = true
codegen-units = 1
# sl0p: fast iteration profile for locally-deployed builds.
#
# `release` is tuned for shipping: fat LTO plus codegen-units = 1 means every
# rebuild redoes whole-program optimization on a single core, which costs ~3
# minutes per one-line change. For a build we are only going to look at in a
# terminal that is pure waste - zellij is I/O bound on a human, not on codegen.
#
# This keeps opt-level 3 (so it still feels like a real build) but drops LTO,
# parallelises codegen across cores, and keeps the incremental cache.
#
# cargo build --profile fastdev -p zellij -> target/fastdev/zellij
#
# Use `--release` for anything you actually ship or benchmark.
[profile.fastdev]
inherits = "release"
lto = false
codegen-units = 16
strip = false
incremental = true
debug = false
# sl0p: the crates we actually edit are split into many small codegen units, so
# a one-line change recompiles a sliver of the crate instead of a sixteenth of
# it. zellij-server is one enormous crate, and that is the whole edit loop:
# measured on the same one-line change to pane_boundaries_frame.rs, from `git
# checkout` of the file to a linked binary,
#
# codegen-units = 16 52s <- what the loop used to cost
# codegen-units = 256 6s
#
# opt-level is deliberately left at 3: dropping it to 1 saved another second
# (5s), which is not worth a slower binary. Nothing else moved the needle --
# linking the 69MB binary is ~2s, and lld did not improve on that.
[profile.fastdev.package.zellij-server]
codegen-units = 256
[profile.fastdev.package.zellij-utils]
codegen-units = 256
[profile.fastdev.package.zellij-client]
codegen-units = 256
[profile.fastdev.package.zellij]
codegen-units = 256
[package.metadata.deb]
depends = "$auto"
license-file = ["LICENSE.md", "4"]
assets = [
["target/release/zellij", "usr/bin/zellij", "755"],
["GOVERNANCE.md", "usr/share/doc/zellij/GOVERNANCE.md", "644"],
["README.md", "usr/share/doc/zellij/README.md", "644"],
]
[package.metadata.binstall]
pkg-url = "{ repo }/releases/download/v{ version }/{ name }-{ target }.tar.gz"
bin-dir = "{ bin }{ binary-ext }"
pkg-fmt = "tgz"
[features]
# See remarks in zellij_utils/Cargo.toml
default = ["plugins_from_target", "vendored_curl", "web_server_capability"]
plugins_from_target = ["zellij-utils/plugins_from_target"]
disable_automatic_asset_installation = ["zellij-utils/disable_automatic_asset_installation"]
vendored_curl = ["zellij-utils/vendored_curl"]
unstable = ["zellij-client/unstable", "zellij-utils/unstable"]
web_server_capability = ["zellij-client/web_server_capability", "zellij-server/web_server_capability", "zellij-utils/web_server_capability"]
# uncomment this when developing plugins in the Zellij UI to make plugin compilation faster
# [profile.dev.package."*"]
# opt-level = 3
|