kaldo provides the ability to share aliases across all your shells. It supports Windows, Linux, & macOS along with bash, zsh, fish, pwsh, and powershell (Windows Powershell).
Installation
Windows
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
iwr -useb https://raw.githubusercontent.com/cpendery/kaldo/main/install.ps1 | iexmacOS / Linux
curl -sSfL https://raw.githubusercontent.com/cpendery/kaldo/main/install.sh | sh -s
Initialize Shell Plugin
ignore this section if you used the install script
If installed manually, you need to initialize the shell plugin for each shell you want to share aliases with. After using your respective shell commands below, restart your shell to get shared aliases.
# bash echo $(kaldo init bash) >> ~/.bashrc # zsh echo $(kaldo init zsh) >> ~/.zshrc # fish echo $(kaldo init fish) >> ~/.config/fish/config.fish # pwsh echo $(kaldo init pwsh) >> $profile # powershell echo $(kaldo init powershell) >> $profile
Configure Aliases
All aliases are stored inside your ~/.kaldorc toml file. Below is an example of how to define shell specific and cross shell aliases. The following tables result in custom aliases while no table results in an alias for every shell.
bash: aliases for the bash shellzsh: aliases for the zsh shellfish: aliases for the fish shellpowershell: aliases for Windows Powershellpwsh: aliases for Powershell Core
There are also 2 custom group tables that help reduce duplication across similar shells.
sh: aliases forbash,zsh, andfishpower: aliases forpowershellandpwsh
# .kaldorc ek = 'echo "kaldo"' # when outside of a table, the alias is loaded for all your shells [bash] ek = 'echo "kaldo on bash"' # inside the bash table, this alias is only provided for bash and overrides your shared alias