⚡️ Installation
Quick setup
tip
If required append -b <tag>
or -b <branch>
e.g:
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -i skip -b main
Minimal configuration
sh -c "$(curl -fsSL https://git.io/get-zi)" --
Only update / install repository
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -i skip
Minimal configuration + annexes
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -a annex
Minimal configuration + annexes + zdharma/zunit
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -a zunit
Minimal configuration with loader
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -a loader
The installer will download loader and add snippet below to the .zshrc
file.
if [[ -r "${XDG_CONFIG_HOME:-$HOME/.config}/zi/init.zsh" ]]; then source "${XDG_CONFIG_HOME:-$HOME/.config}/zi/init.zsh" && zzinitfi
tip
The loader can be manually fetched from links below to any location on the system, and sourced from .zshrc
.
Then reload shell with: exec zsh
. All done!
Manual Setup
Setup ZI directory
zi_home="${HOME}/.zi" && mkdir -p $zi_home
Clone repository
git clone https://github.com/z-shell/zi.git "${zi_home}/bin"
Source zi.zsh
in your .zshrc
from previously created directory:
zi_home="${HOME}/.zi"source "${zi_home}/bin/zi.zsh"
Enable completions:
info
The next two lines must be below the above two:
autoload -Uz _zi(( ${+_comps} )) && _comps[zi]=_zi
Post-install
After a fresh install, recommended to reload the shell with exec zsh
and compile ZI with zi self-update
.
Run zi -h
to see all available commands. Increase ZI functionality, performance or get started by exploring the wiki.
If you have any issue or need help 🤦♂️, lets discuss it or open an issue in any language.
It helps us to improve and make ZI better. Don't forget to help the project: share, contribute, or translate 🌐 🥰 🤓.
Let's glue everything together to create a toolchain that works for US 🚀.
Have ideas?
Suggest your configuration: z-shell/playground
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -a ???
Need warm-up?
Docker Alpine
docker run --rm -it ghcr.io/z-shell/zd:latest
Turbo ZI in Docker
If you create a Docker image that uses ZI, install Turbo-loaded plugins before the shell starts interactively, with the @zi-scheduler
function in such a way, that it:
- installs plugins without waiting for the prompt (i.e. it's script friendly),
- installs all plugins instantly, without respecting the wait'' argument.
To accomplish this, use burst argument and call @zi-scheduler
function:
RUN zsh -i -c -- '@zi-scheduler burst || true'
- An example: Dockerfile
- In action: Dockerfile
Build ZI Module
Without ZI
sh -c "$(curl -fsSL https://git.io/get-zi)" -- -a zpmod
With ZI
info
ZI has to be installed to build the module. Module repository: z-shell/zpmod
zi module build
To enable debug messages from the module set:
typeset -g ZI_MOD_DEBUG=1
Available installer links
⚙️ Install Library: ✔️ | Status page: ✔️