Zsh
My shell of choice. My config for it can be seen here.
Notesβ
- Exported variables get passed on to child processes. Non-exported variables do not.
- I don't need to add
function
text before function definition. - Search
zshall
man page to find all zsh widgets and more things. - I can use
zsh/zprof
to profile zsh startup time. Docs for it can be seen inzshmodules
. zsh -x
- See what Zsh executes when it starts new shell.cmd -
and TAB will list options for command.
Codeβ
# Read function definition
whence -f ..
# See where the it was defined
whence -v
# Bind comand to alt key
# alt+i will run 'a' command.
# \e means opt key
bindkey -s '\ei' '^Ua^M'
# See what is binded to a key
# See what is binding to β + E
bindkey '^E'
# Run zsh without sourcing zshrc
zsh -f
# Set alias to external command
alias fin='command fd'
# List all bindings
bindkey
Linksβ
- Zsh custom widgets
- Prezto - Instantly Awesome Zsh.
- zsh-dirnav - Directory navigation functions for zsh.
- Zsh prompt with asynchronous Git status
- ZSH History Database
- Building portable Zsh
- Speeding up Zsh
- Some zshrc tricks (2020) (Lobsters)
- 5 Types Of ZSH Aliases You Should Know (HN)
- Zsh and Fishβs simple but clever trick for highlighting missing linefeeds (2020) (HN)
- Nice Zsh configs/tips
- tabtab - Generate CLI completions for zsh, bash, and fish.
- Oh My Zsh - Open source, community-driven framework for managing your zsh configuration.
- zsh-defer - Deferred execution of zsh commands.
- Zsh Compinit ... RTFM (2018) - Optimizing Zsh startup time.
- Mastering Zsh - Advanced topics to take advantage of zsh.
- Zsh Tricks to Blow Your Mind (2021) (HN)
- sandboxd - Speed up your bashrc / zshrc: avoids running (slow) setup commands until you actually need them.
- zsh-bin - Statically-linked, hermetic, relocatable Zsh.
- Zim - Modular, customizable, and blazing fast Zsh framework. (Web) (HN)
- A User's Guide to ZSH
- zsh-bench - Benchmark for interactive Zsh.
- s/bash/zsh/g (2021) (HN)
- ZSH Completions How To (HN)
- A Guide to Zsh Expansion with Examples (2021)
- Zi - Swiss Army Knife for Zsh. (Docs)
- Zsh Plugin Standard
- Zsh Native Scripting Handbook
- zshbrev - Allows you to mix zsh code and brev code.