Commands
Let’s look what other commands antidote has available for us!
Home
You can see where antidote is keeping the plugins with the home command:
$ antidote home
$HOME/.cache/antidote
Of course, you can remove the entire thing with:
rm -rf $(antidote home)
if you decide to start fresh or to use something else.
If you clear out your plugins, don’t forget to also run:
rm ~/.zsh_plugins.zsh
Install
You can quickly add a plugin to your plugins file with antidote install:
$ antidote install zsh-users/zsh-autosuggestions
Bundle 'zsh-users/zsh-autosuggestions' added to '$HOME/.zsh_plugins.txt'.
If you have an alternate location for your plugins file, you can provide that too:
$ antidote install zsh-users/zsh-history-substring-search ${ZDOTDIR:-$HOME}/myplugins.conf
Bundle 'zsh-users/zsh-history-substring-search' added to '$HOME/.zsh/myplugins.conf'.
Don’t forget to reload zsh afterwards to load the plugin you just added!
List
You can list the plugins you have cloned to your antidote home folder:
$ antidote list
$HOME/.cache/antidote/github.com/zsh-users/zsh-autosuggestions https://github.com/zsh-users/zsh-autosuggestions
$HOME/.cache/antidote/github.com/zsh-users/zsh-history-substring-search https://github.com/zsh-users/zsh-history-substring-search
# ...
Load
You can use antidote load in your .zshrc to clone and source everything in your
plugins file, which by default is ${ZDOTDIR:-$HOME}/.zsh_plugins.txt:
# .zshrc
# make a static plugins file and source it to load all your plugins
antidote load
It also takes a parameter if you prefer to use a custom plugins file:
# .zshrc
antidote load ${ZDOTDIR:-$HOME}/myplugins.conf
Path
You can see the path being used for a cloned bundle.
$ antidote path ohmyzsh/ohmyzsh
$HOME/.cache/antidote/github.com/ohmyzsh/ohmyzsh
This is particularly useful for projects like oh-my-zsh that rely on storing its path in
the $ZSH environment variable:
$ ZSH=$(antidote path ohmyzsh/ohmyzsh)
Purge
You can remove a bundle completely by purging it:
$ antidote purge ohmyzsh/ohmyzsh
Removing ohmyzsh/ohmyzsh...
You can also remove all antidote bundles and the static cache file to start fresh:
$ rm -rf $(antidote home)
$ rm ${ZDOTDIR:-$HOME}/.zsh_plugins.zsh
Snapshot
Snapshot commands are covered in detail in the Snapshots section.
Update
Antidote can update itself, and all bundles in a single pass.
Just run:
$ antidote update
Updating bundles...
antidote: checking for updates: mattmc3/antidote
antidote: checking for updates: zsh-users/zsh-autosuggestions
antidote: checking for updates: zsh-users/zsh-completions
antidote: checking for updates: zsh-users/zsh-history-substring-search
...
Waiting for bundle updates to complete...
Bundle mattmc3/antidote update check complete.
antidote: updated: mattmc3/antidote 22c72eb -> a8271f8
a8271f8 Merge pull request #260 from mattmc3/v2.0.10
22c72eb Update changelog
Bundle updates complete.
...