Requirements • Install • Usage • What's working?
Zana 📦 aims to be like Mason.nvim 🧱, but with the goal of supporting 🌈 not only Neovim, but rather any other editor 🫶.
Zana is swahili for "tools" or "tooling".
A minimal package manager for Neovim (and other editors) which uses the Zana Registry to install and manage packages.
Easily install and manage LSP servers, DAP servers, linters, and formatters.
Currently, Zana is in beta and under active development.
Zana is a TUI, therefore you need to have a terminal emulator available.
Besides that, we shell out to npm
, pip
, cargo
, go
, and git
to install packages,
depending on the package type.
E.g. if you want to install pkg:npm
packages, you need to have npm
installed.
For the packages to work in Neovim, you need to Zana.nvim installed.
Just head over to the download page or grab it directtly from the releases.
The heart of Zana is its zana-lock.json
file.
This file is used to keep track of the installed packages and their versions.
You can tell Zana where to find the zana-lock.json
and
the packages by setting the environment variable ZANA_HOME
.
If ZANA_HOME
is not set,
Zana will look for the zana-lock.json
file in the default locations:
- Linux:
$XDG_CONFIG_HOME/zana/zana-lock.json
or$HOME/.config/zana/zana-lock.json
- macOS:
$HOME/Library/Application Support/zana/zana-lock.json
- Windows:
%APPDATA%\zana\zana-lock.json
If the file does not exist, Zana will create it for you (when you install a package).
- Start Zana by running
zana
in your terminal. - Use the arrow keys (or hjkl) to navigate the packages.
- Use
enter
to install a package. - Use
enter
to update a package. - Use
backspace
to remove a package. - Use
/
to filter packages. - Use
q
to quit Zana.
It's advised to keep the zana-lock.json
file in version control.
If you want the installed packages to be available in your path, you can add the following to your shell configuration file:
add to ~/.bashrc
:
source <(zana env)
add to ~/.zshrc
:
source <(zana env)
or with evalcache for zsh,
add to ~/.zshrc
:
_evalcache zana env zsh
add to profile
:
zana env powershell | Invoke-Expression
If you want autocompletion for the CLI commands, you can add the following to your shell configuration file:
add to ~/.bashrc
:
source <(zana completion bash)
add to ~/.zshrc
:
source <(zana completion zsh)
or with evalcache for zsh,
add to ~/.zshrc
:
_evalcache zana completion zsh
add to ~/.config/fish/completions/zana.fish
:
zana completion fish > ~/.config/fish/completions/zana.fish
add to profile
:
zana completion powershell | Invoke-Expression
You can run zana --help
to see the available CLI options.
- install/add: Install packages (e.g.,
zana install pkg:npm/@mistweavercokulala-ls@0.1.0 pkg:pypi/black pkg:golang/golangci-lint
) - list/ls: Lists all installed packages (or with
--all
/-A
flag all available packages. - update/up: Update packages (e.g.,
zana update pkg:npm/@mistweaverco/kulala-ls pkg:pypi/black@latest
) - remove/rm/delete: Remove packages (e.g.,
zana remove pkg:npm/@mistweaverco/kulala-ls pkg:pypi/black pkg:golang/golangci-lint
)
The update
command accepts the an optional --all
/-A
flag to update all packages.
- health: Checks for requirements (for shelling out to install packages)
Zana uses a basepath to install packages of different types.
If you have set the ZANA_HOME
environment variable,
the basepath will be $ZANA_HOME/packages
.
If ZANA_HOME
isn't set, the basepath is:
- Linux:
$XDG_CONFIG_HOME/zana/packages
or$HOME/.config/zana/packages
- macOS:
$HOME/Library/Application Support/zana/packages
- Windows:
%APPDATA%\zana\packages
The packages are installed in the following directories:
pkg:npm
:$basepath/npm
pkg:pypi
:$basepath/pypi
pkg:github
:$basepath/github
pkg:golang
:$basepath/golang
pkg:cargo
:$basepath/cargo
- registry updates on startup
- Updates available for installed packages?
- Filtering packages
- Vim keymaps
- Install
pkg:npm
packages - Update
pkg:npm
packages - Remove
pkg:npm
packages - Install
pkg:github
packages - Update
pkg:github
packages - Remove
pkg:github
packages - Install
pkg:pypi
packages - Update
pkg:pypi
packages - Remove
pkg:pypi
packages - Install
pkg:golang
packages - Update
pkg:golang
packages - Remove
pkg:golang
packages - Install
pkg:cargo
packages - Update
pkg:cargo
packages - Remove
pkg:cargo
packages