Skip to content

Dev install

./dev-install.sh symlinks the working tree into $XDG_CONFIG_HOME/<appname> and drops a launcher in $HOME/.local/bin. Edits in the checkout are live on the next launch — no reinstall required.

Use it for interactive testing alongside the isolated automated smoke tests.

Source: dev-install.sh.

Terminal window
./dev-install.sh # symlinks repo → ~/.config/blak-dev
blak-dev # NVIM_APPNAME=blak-dev nvim

That’s it. Open a buffer, :BlakDoctor, exercise the change.

Flag Default What
--appname NAME blak-dev Use a custom NVIM_APPNAME (and matching launcher name).
--force, -f off Repoint an existing config symlink. Unrelated launchers are preserved.
--uninstall, -u Remove the symlink to this checkout and a script-managed launcher. Leaves runtime data dirs alone.
--status, -s Print current install state without changing anything.
--help, -h Show usage.
Var Default Same as
BLAK_APPNAME blak-dev --appname
BLAK_BIN_DIR $HOME/.local/bin (launcher location)
XDG_CONFIG_HOME $HOME/.config (config parent)
$XDG_CONFIG_HOME/<appname> symlink → this checkout
$BLAK_BIN_DIR/<appname> launcher script (NVIM_APPNAME=<appname> exec nvim)

That’s it on the install side. Runtime state lands under the per-appname XDG dirs as Neovim runs:

$XDG_DATA_HOME/<appname>/lazy/ installed plugins
$XDG_STATE_HOME/<appname>/blak/ extras.json + rollback snapshots
$XDG_CACHE_HOME/<appname>/ caches

Different app names keep plugin installations and runtime state separate. App names linked to the same checkout still share source files, user.lua, and the plugin lockfile. Use separate checkouts for independent configuration.

The point of dev-install is the live edit loop. Editing lua/blak/extras/lang/zig.lua in your IDE means the next blak-dev launch picks it up — no git pull && reinstall && pray.

The launcher script carries a small marker comment so --status and --uninstall know it’s safe to operate on (vs. a manually-created launcher of the same name).

Want to test two branches at once? Use different appnames:

Terminal window
cd ~/Developer/blak.nvim
./dev-install.sh --appname blak-main
git worktree add ../blak-zig -b feature/zig
cd ../blak-zig
./dev-install.sh --appname blak-zig
blak-main # main branch
blak-zig # feature branch

Each has its own plugin install, its own extras state, and its own rollback snapshots.

Terminal window
./dev-install.sh --uninstall # removes symlink + launcher

The runtime state dirs ($XDG_DATA_HOME/blak-dev, etc.) are intentionally not removed — they’re expensive to rebuild and might still be useful. Delete them manually if you want a clean slate:

Terminal window
rm -rf ~/.local/share/blak-dev ~/.local/state/blak-dev ~/.cache/blak-dev
Terminal window
./dev-install.sh --status

Prints whether the symlink exists, where it points, whether the launcher exists, and whether it’s the one this script created.

Use Script
Trying Blak from the public repo install.sh
Hacking on Blak locally dev-install.sh
Running CI / smoke tests make smoke (or no install at all, the script sets the runtime path)