aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoruser <user@clank>2026-08-12 20:03:19 +0200
committeruser <user@clank>2026-08-12 20:03:19 +0200
commit04ce010651a73a99d57e8b1c30bcc4f1346c9c52 (patch)
tree61ae53c504d4428e19ad2d15c37bf1cf874c4d08
parentsl0p: rename to sl0ppij behind a branding seam (diff)
downloadsl0ppi-04ce010651a73a99d57e8b1c30bcc4f1346c9c52.tar.gz
sl0ppi-04ce010651a73a99d57e8b1c30bcc4f1346c9c52.tar.xz
sl0ppi-04ce010651a73a99d57e8b1c30bcc4f1346c9c52.zip
build: follow the rename through config, packaging and docs
config/config.kdl plugin path -> ~/.config/sl0ppij/plugins, builtin plugins -> the sl0ppij: URL scheme. Verified to load under the renamed binary ("[CONFIG FILE]: Well defined."). install-config.sh syncs to ~/.config/sl0ppij install.sh a stock zellij on the target is no longer a warning, it is just a fact: the two coexist stage.sh drops the "renaming at package time is a fig leaf" note Makefile builds `-p zellij` (package) and ships `sl0ppij` (binary); `make check` now also gates the root package, using the prebuilt asset plugins so it does not need debug wasm docs/ rename.md records what was done, what was deliberately left (plugin-internal strings live in prebuilt wasm), and the verification actually performed
-rw-r--r--.gitignore8
-rw-r--r--Makefile21
-rw-r--r--config/README.md16
-rw-r--r--config/config.kdl18
-rw-r--r--docs/rename.md110
-rw-r--r--docs/roadmap.md28
-rwxr-xr-xpackaging/install-config.sh4
-rwxr-xr-xpackaging/install.sh6
-rwxr-xr-xpackaging/stage.sh6
9 files changed, 128 insertions, 89 deletions
diff --git a/.gitignore b/.gitignore
index 8201aef..0c5dd6d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,6 +1,8 @@
-# build artifacts
-/target/
-**/target/
+# build artifacts (dir, or a symlink to a shared cache on a cramped dev box --
+# the debug-plugin include! path resolves relative to the source tree, so
+# CARGO_TARGET_DIR alone is not enough)
+/target
+**/target
/dist/
/build/
diff --git a/Makefile b/Makefile
index 598e60b..029ee75 100644
--- a/Makefile
+++ b/Makefile
@@ -15,11 +15,12 @@ STAGE := $(ROOT)/packaging/stage/$(PKG)
OUT := $(ROOT)/packaging/out
VENDOR := $(ROOT)/vendor/cache
-# Until docs/rename.md is implemented the fork still builds a binary called
-# `zellij`. Everything downstream refers to $(BIN_NAME); flip CARGO_BIN when the
-# rename lands and nothing else here changes.
+# The fork builds a binary named sl0ppij (via [[bin]] in sl0ppij/Cargo.toml)
+# while the cargo *package* is still called zellij -- see zellij-utils/src/branding.rs.
+# Hence: build with `-p zellij`, ship `sl0ppij`.
BIN_NAME := sl0ppij
-CARGO_BIN := zellij
+CARGO_PKG := zellij
+CARGO_BIN := sl0ppij
# Pins — keep in sync with FORKS.md.
PI_VERSION := 0.84.1
@@ -45,13 +46,13 @@ version: ## Print the sl0ppi version and what it is built from
.PHONY: dev
dev: ## Fast non-LTO build of sl0ppij (~3s incremental) for local testing
- cd $(FORK) && cargo build --profile fastdev -p $(CARGO_BIN)
- @echo "-> $(FORK)/target/fastdev/$(CARGO_BIN)"
+ cd $(FORK) && cargo build --profile fastdev -p $(CARGO_PKG)
+ @echo "-> $(FORK)/target/fastdev/$(BIN_NAME)"
.PHONY: build
build: ## Release build of sl0ppij (LTO, ~3min — not for the edit loop)
- cd $(FORK) && cargo build --release -p $(CARGO_BIN)
- @echo "-> $(FORK)/target/release/$(CARGO_BIN)"
+ cd $(FORK) && cargo build --release -p $(CARGO_PKG)
+ @echo "-> $(FORK)/target/release/$(BIN_NAME)"
.PHONY: plugins
plugins: ## Build the in-tree wasm plugins (pane-finder)
@@ -60,6 +61,10 @@ plugins: ## Build the in-tree wasm plugins (pane-finder)
.PHONY: check
check: ## Cheap compile gate
cd $(FORK) && cargo check -p zellij-server
+ # the root package pulls in `plugins_from_target`, which wants debug wasm
+ # plugins; check against the prebuilt asset plugins instead
+ cd $(FORK) && cargo check -p $(CARGO_PKG) --no-default-features \
+ --features vendored_curl,web_server_capability
.PHONY: test
test: ## Unit tests for the crates we actually modify
diff --git a/config/README.md b/config/README.md
index 350384b..0db29ac 100644
--- a/config/README.md
+++ b/config/README.md
@@ -18,11 +18,15 @@ versioned by hand-rolled `config.kdl.pre-<thing>` backups.
Edit **here**, then `make install-config` to sync into your live config dir.
Do not edit the live dotfiles directly any more — they are now a build output.
-## Known rewrites still pending (see docs/rename.md)
+## Rename status
-This is a *faithful* snapshot, so it still contains development-machine paths
-that the rename + packaging work has to parameterise:
+Repointed at sl0ppij's own dirs now that the rename has landed (docs/rename.md):
-- `file:~/.config/zellij/plugins/pane-finder.wasm` (x2) → sl0ppij's own config dir
-- header comments referencing `~/.config/zellij/...` and `~/lol/zellij`
-- `theme "gruber-darker-pop"` assumes `themes/` is installed alongside
+- `file:~/.config/sl0ppij/plugins/pane-finder.wasm`
+- builtin plugins use the `sl0ppij:` URL scheme (`zellij:` still parses)
+- comments no longer reference `~/.config/zellij` or the old `~/lol/zellij` checkout
+
+Verified with `sl0ppij setup --check` against a staged config dir: *CONFIG FILE:
+Well defined*.
+
+Still assumed: `theme "gruber-darker-pop"` requires `themes/` installed alongside.
diff --git a/config/config.kdl b/config/config.kdl
index 7f15c8c..8ed9370 100644
--- a/config/config.kdl
+++ b/config/config.kdl
@@ -1,4 +1,4 @@
-// ~/.config/zellij/config.kdl
+// ~/.config/sl0ppij/config.kdl
// "unlock-first" (non-colliding) setup: Zellij grabs almost no keys by default.
// Leader: Ctrl g -> unlocks into Normal mode, then one letter picks a mode:
// p pane t tab r resize m move s scroll/search o session
@@ -130,7 +130,7 @@ keybinds clear-defaults=true {
// takes effect on the next launch instead of being masked by the server's
// in-memory module cache. Costs a wasm recompile (~100-300ms) per launch.
bind "g" {
- LaunchOrFocusPlugin "file:~/.config/zellij/plugins/pane-finder.wasm" {
+ LaunchOrFocusPlugin "file:~/.config/sl0ppij/plugins/pane-finder.wasm" {
floating true
move_to_focused_tab true
skip_plugin_cache true
@@ -163,21 +163,21 @@ keybinds clear-defaults=true {
SwitchToMode "Locked"
}
bind "a" {
- LaunchOrFocusPlugin "zellij:about" {
+ LaunchOrFocusPlugin "sl0ppij:about" {
floating true
move_to_focused_tab true
};
SwitchToMode "Locked"
}
bind "s" {
- LaunchOrFocusPlugin "zellij:share" {
+ LaunchOrFocusPlugin "sl0ppij:share" {
floating true
move_to_focused_tab true
};
SwitchToMode "Locked"
}
bind "l" {
- LaunchOrFocusPlugin "zellij:layout-manager" {
+ LaunchOrFocusPlugin "sl0ppij:layout-manager" {
floating true
move_to_focused_tab true
};
@@ -232,7 +232,7 @@ keybinds clear-defaults=true {
// only binds bare ';' (repeat f/t), never Ctrl-;. Like Ctrl-= / Ctrl--
// above it needs the kitty keyboard protocol to be distinguishable.
bind "Ctrl ;" {
- LaunchOrFocusPlugin "file:~/.config/zellij/plugins/pane-finder.wasm" {
+ LaunchOrFocusPlugin "file:~/.config/sl0ppij/plugins/pane-finder.wasm" {
floating true
move_to_focused_tab true
skip_plugin_cache true
@@ -269,11 +269,11 @@ keybinds clear-defaults=true {
}
// ── look & feel ────────────────────────────────────────────────────────────
-// ~/.config/zellij/themes/templeos.kdl — 16-color VGA, white desktop, blue task
+// ~/.config/sl0ppij/themes/templeos.kdl — 16-color VGA, white desktop, blue task
// frames. Run `templeos-term on` to put the *terminal* into the same palette.
// gruber-darker-pop = stock gruber-darker + a `frame_unselected` block, so the
// FOCUSED pane's frame (gruber yellow) pops against recessive gray inactive ones.
-// Defined in ~/.config/zellij/themes/gruber-darker-pop.kdl — tune `frame_unselected`
+// Defined in ~/.config/sl0ppij/themes/gruber-darker-pop.kdl — tune `frame_unselected`
// `base` there: lower = more recessive, higher = louder. Revert with "gruber-darker".
theme "gruber-darker-pop"
// Fallbacks if you get tired of God's own colors: catppuccin-mocha, gruvbox-dark,
@@ -283,7 +283,7 @@ ui {
pane_frames {
rounded_corners true // (was false: "TempleOS does not do rounded. 640x480 or death.")
hide_session_name false
- // sl0p fork only (~/lol/zellij, branch sl0p/base): "left" | "center" | "right".
+ // sl0p fork only (sl0ppij): "left" | "center" | "right".
// Upstream zellij hardcodes full-frame titles flush left.
title_alignment "center"
// sl0p fork only.
diff --git a/docs/rename.md b/docs/rename.md
index fc9be9b..a2c45f1 100644
--- a/docs/rename.md
+++ b/docs/rename.md
@@ -1,28 +1,29 @@
# The rename: zellij → sl0ppij
+**Status: implemented.** See commit `sl0p: rename to sl0ppij behind a branding
+seam`.
+
**Goal:** a machine can have stock zellij and sl0ppij installed at the same time,
running at the same time, without sharing a single byte of state.
-Today the fork still builds a binary called `zellij` and `~/bin/sl0ppij` is a
-symlink to it — so on any machine with real zellij, sl0ppij would fight it over
-`~/.config/zellij`, the socket dir, and `$ZELLIJ*`.
-
## Isolation checklist
-A rename is "done" when all of these are disjoint from upstream:
+All disjoint from upstream as of the rename commit:
-| surface | upstream today | after |
-|---|---|---|
-| binary name | `zellij` | `sl0ppij` |
-| config dir | `~/.config/zellij` | `~/.config/sl0ppij` |
-| cache/data dir | `ProjectDirs("", "", "Zellij")` | `ProjectDirs("", "", "sl0ppij")` |
-| system config | `/etc/zellij` | `/etc/sl0ppij` |
-| socket dir | `$TMPDIR/zellij-$UID` | `$TMPDIR/sl0ppij-$UID` |
-| log dir/file | `…/zellij-log/zellij.log` | `…/sl0ppij-log/sl0ppij.log` |
-| env marker | `ZELLIJ=0` | see "env vars" below |
-| session env | `ZELLIJ_SESSION_NAME`, `ZELLIJ_PANE_ID`, … | ditto |
-| plugin URL scheme | `zellij:about` | `sl0ppij:about` (+ accept `zellij:`) |
-| desktop/shell assets | `assets/zellij.desktop`, `zellij.rc` | renamed |
+| surface | upstream | sl0ppij | done |
+|---|---|---|---|
+| binary name | `zellij` | `sl0ppij` | ✅ |
+| config dir | `~/.config/zellij` | `~/.config/sl0ppij` | ✅ |
+| cache/data dir | `ProjectDirs("org","Zellij Contributors","Zellij")` | `ProjectDirs("foo","sl0p","sl0ppij")` | ✅ |
+| system config | `/etc/zellij` | `/etc/sl0ppij` | ✅ |
+| system data | `/usr/share/zellij` | `/usr/share/sl0ppij` | ✅ |
+| socket/tmp dir | `$TMPDIR/zellij-$UID` | `$TMPDIR/sl0ppij-$UID` | ✅ |
+| log dir/file | `…/zellij-log/zellij.log` | `…/sl0ppij-log/sl0ppij.log` | ✅ |
+| env vars | `ZELLIJ*` | `SL0PPIJ*` **and** `ZELLIJ*` (ours wins) | ✅ |
+| plugin URL scheme | `zellij:about` | `sl0ppij:about` (accepts `zellij:`) | ✅ |
+| help / CLI text | "zellij" | "sl0ppij" | ✅ |
+| default-plugin text | "zellij" | — | ⬜ needs a wasm rebuild |
+| desktop/shell assets | `assets/zellij.desktop`, `zellij.rc` | — | ⬜ packaging-only, unused so far |
## Where the work actually is
@@ -46,6 +47,16 @@ Encouragingly small and centralised:
- **user-visible help strings** — `"zellij setup --check"`, `"zellij -l compact"`
etc. inside `default-plugins/status-bar` tips and `about`.
+## What was left out, on purpose
+
+- **`default-plugins/*` strings** (the About screen, status-bar tips) still say
+ "zellij". They live inside prebuilt `.wasm` blobs in
+ `zellij-utils/assets/plugins/`, so changing them means rebuilding the plugins
+ and committing new binaries — a separate, chunky commit.
+- **`assets/zellij.desktop` / `zellij.rc`** are only used by distro packaging and
+ the Windows build, neither of which we ship yet.
+- **Crate names** (`zellij-utils`, `zellij-tile`, …) — see below.
+
## Strategy: one seam, not a sed
Do **not** `sed -i s/zellij/sl0ppij/g` the tree. Every touched upstream line is a
@@ -67,30 +78,57 @@ Instead:
spawn the server. Verify it resolves via `current_exe()` and not a hardcoded
`"zellij"` on `$PATH`, or a sl0ppij client will start a zellij server.
-## Open decision: env vars
+## Decided: env vars keep both spellings
+
+Renaming `ZELLIJ=0` → `SL0PPIJ=0` outright would break every third-party thing
+that detects "am I in a multiplexer" (shell prompts, starship, nested-session
+guards, and our own `pi-ext`).
+
+So **both are exported**, and `SL0PPIJ*` takes precedence on read:
-Renaming `ZELLIJ=0` → `SL0PPIJ=0` gives true isolation but breaks every third-party
-thing that detects "am I in a multiplexer" (shell prompts, starship, direnv
-snippets, nested-session guards, and possibly our own `pi-ext`).
+| variable | ours | upstream's |
+|---|---|---|
+| marker | `SL0PPIJ` | `ZELLIJ` |
+| session | `SL0PPIJ_SESSION_NAME` | `ZELLIJ_SESSION_NAME` |
+| pane | `SL0PPIJ_PANE_ID` | `ZELLIJ_PANE_ID` |
+| socket dir | `SL0PPIJ_SOCKET_DIR` | `ZELLIJ_SOCKET_DIR` |
+| config file/dir, layout dir | `SL0PPIJ_CONFIG_*`, `SL0PPIJ_LAYOUT_DIR` | `ZELLIJ_CONFIG_*`, `ZELLIJ_LAYOUT_DIR` |
+
+`branding::import_compat_env()` runs first thing in `main()` and folds an
+inherited `ZELLIJ_*` into its `SL0PPIJ_*` spelling, which is what makes the
+clap-derived arguments honour both (clap accepts only one env name per arg).
+
+Note the spelling is `SL0PPIJ` (zero), matching the binary name.
+
+> Because both spellings are exported, a pi running inside sl0ppij still sees
+> `$ZELLIJ`, so **pi-ext needed no changes**.
-Proposal: **export both.** `SL0PPIJ*` is authoritative and what our own code
-reads; `ZELLIJ*` is exported too so the ecosystem keeps working, with a config
-option `export_zellij_env_vars true|false` for people who want strict isolation.
-Reading follows the same order (`SL0PPIJ_*` first, then `ZELLIJ_*`).
+## Verification (all performed)
-Needs a decision before implementation starts.
+**Unit tests** in `branding.rs`: no shipped default path contains the string
+`zellij`; env precedence is ours-then-upstream; `set_env_var` writes both
+spellings; every pair differs only by prefix.
-## Verification
+**Suites:** `zellij-utils` 471 passed, `zellij-server` 1499 passed.
-The rename is testable, so it should have a test:
+**Live, against a box already running stock zellij:**
-```bash
-# no state overlap while both run
-sl0ppij -s a & zellij -s b &
-test -d ~/.config/sl0ppij && test -d ~/.config/zellij
-ls $TMPDIR/sl0ppij-$UID $TMPDIR/zellij-$UID # both exist, disjoint
-sl0ppij list-sessions # shows a, not b
-zellij list-sessions # shows b, not a
```
+$ sl0ppij --version -> sl0ppij 0.45.0+sl0p1
+$ sl0ppij setup --check -> ~/.config/sl0ppij, ~/.cache/sl0ppij,
+ /usr/share/sl0ppij
+$ ls -d /tmp/sl0ppij-1000 /tmp/zellij-1000 -> both exist, disjoint
+$ zellij list-sessions -> 3 sessions
+$ sl0ppij list-sessions -> "No active sl0ppij sessions found."
+```
+
+**Env precedence, end to end:**
+
+| set | resulting CONFIG DIR |
+|---|---|
+| `ZELLIJ_CONFIG_DIR=/tmp/cfg-upstream` | `/tmp/cfg-upstream` |
+| `SL0PPIJ_CONFIG_DIR=/tmp/cfg-ours` | `/tmp/cfg-ours` |
+| both | `/tmp/cfg-ours` |
-Plus a unit test asserting no shipped default path contains the string `zellij`.
+**Config:** the rebranded `config/config.kdl` loads under the renamed binary
+(`[CONFIG FILE]: Well defined.`).
diff --git a/docs/roadmap.md b/docs/roadmap.md
index 9bed053..7a7bf1f 100644
--- a/docs/roadmap.md
+++ b/docs/roadmap.md
@@ -10,27 +10,25 @@
- [x] `Makefile` + `packaging/` — build → vendor → stage → tarball
- [x] proven: vendored bun runs vendored pi, so the tarball needs no system node
-## Phase 1 — the rename (next, and the biggest chunk)
+## Phase 1 — the rename ✅
-Implement [rename.md](rename.md): sl0ppij gets its own binary name, config dir,
-cache dir, socket dir, log file and plugin URL scheme, so it coexists with a
-stock zellij.
+[rename.md](rename.md) is implemented: own binary name, config dir, cache dir,
+socket dir, log file and plugin URL scheme, all behind a single `branding.rs`
+seam. `$ZELLIJ*` kept and `$SL0PPIJ*` added on top, ours winning on read.
+Verified live beside a running stock zellij; both suites green.
-**Blocked on one decision: the `$ZELLIJ*` env vars** — rename them (true
-isolation, breaks ecosystem detection) or export both (proposed default). See
-rename.md § "Open decision".
+Left for later (both need work disproportionate to their value right now):
-Done when the two-multiplexer test in rename.md passes.
+- [ ] strings *inside* the default plugins (About screen, status-bar tips) still
+ say "zellij" — they are baked into prebuilt `.wasm` assets
+- [ ] `assets/zellij.desktop` / `zellij.rc`, used only by distro/Windows packaging
## Phase 2 — config becomes portable
-The snapshot in `config/` is faithful, which means it still hardcodes this
-machine:
-
-- `file:~/.config/zellij/plugins/pane-finder.wasm` (x2) → the new config dir
-- header comments pointing at `~/.config/zellij` and `~/lol/zellij`
-- decide whether defaults are also *compiled in* as fallbacks, so a bare
- `sl0ppij` with no config dir still looks right
+- [x] `config/config.kdl` repointed at `~/.config/sl0ppij/` and the `sl0ppij:`
+ plugin scheme; verified to load under the renamed binary
+- [ ] decide whether the opinionated defaults are also *compiled in* as
+ fallbacks, so a bare `sl0ppij` with no config dir still looks right
## Phase 3 — prove the artifact
diff --git a/packaging/install-config.sh b/packaging/install-config.sh
index 85358c8..ffa142a 100755
--- a/packaging/install-config.sh
+++ b/packaging/install-config.sh
@@ -11,9 +11,7 @@
set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
-# Follows the rename: once sl0ppij uses its own dir this default changes and
-# nothing else does.
-DEST="${SL0PPIJ_CONFIG_DIR:-$HOME/.config/zellij}"
+DEST="${SL0PPIJ_CONFIG_DIR:-$HOME/.config/sl0ppij}"
dry_run=0
[ "${1:-}" = "--dry-run" ] || [ "${1:-}" = "-n" ] && dry_run=1
diff --git a/packaging/install.sh b/packaging/install.sh
index 7f92927..967da5c 100755
--- a/packaging/install.sh
+++ b/packaging/install.sh
@@ -122,9 +122,9 @@ case ":$PATH:" in
esac
if command -v zellij >/dev/null 2>&1; then
- warn "a stock zellij is installed on this machine."
- warn "until the rename lands (docs/rename.md), sl0ppij shares zellij's config"
- warn "dir, socket dir and \$ZELLIJ* env vars and the two WILL collide."
+ say "note: a stock zellij is also installed. That is fine -- sl0ppij keeps its"
+ echo " own config dir, cache dir, socket dir and sessions, and the two can"
+ echo " run at the same time."
fi
say "start with: sl0ppij"
diff --git a/packaging/stage.sh b/packaging/stage.sh
index 30ef81d..737d448 100755
--- a/packaging/stage.sh
+++ b/packaging/stage.sh
@@ -38,12 +38,6 @@ mkdir -p "$STAGE"/{bin,libexec,share/sl0ppij/{layouts,themes,plugins},share/pi-e
FORK_BIN="$ROOT/sl0ppij/target/release/$CARGO_BIN"
need "$FORK_BIN" build
install -m755 "$FORK_BIN" "$STAGE/bin/$BIN_NAME"
-if [ "$CARGO_BIN" != "$BIN_NAME" ]; then
- echo "stage: NOTE renaming $CARGO_BIN -> $BIN_NAME at package time." >&2
- echo "stage: This is a fig leaf until docs/rename.md is implemented:" >&2
- echo "stage: the binary still uses zellij's config dir, socket dir and" >&2
- echo "stage: \$ZELLIJ* env vars, so it will collide with a real zellij." >&2
-fi
# --- wasm plugins ----------------------------------------------------------
PANE_FINDER="$ROOT/sl0ppij/target/wasm32-wasip1/release/zj-pane-finder.wasm"