Terminal Setup

1 minute read

Unix shell and Framework installation

Install any of the available shell

brew install --cask iterm2 
brew install --cask wezterm
brew install --cask alacritty

Instead of using the Mac default Bash shell, preferred here is zsh with multiple plugin support.

  • Install latest version of zsh using brew and verify the version.
brew install zsh
zsh --version

with zsh installed, the default profile will be from .zshrc file, where customized profiles can be added

  • Make zsh as system’s default shell
chsh -s $(which zsh)
  • Verify:
echo $SHELL

expected result: /bin/zsh

Install Powerline 10k

git clone https://github.com/romkatv/powerlevel10k.git $ZSH_CUSTOM/themes/powerlevel10k

Run either

p10k configure

OR

Edit ~/.zshrc and set ZSH_THEME="powerlevel10k/powerlevel10k".

Eza instead of ls

https://formulae.brew.sh/formula/eza

brew install eza

Install zshrc plugins

Standard plugins are at $ZSH/plugins/ or ~/.oh-my-zsh/plugins

Custom plugins may be added to $ZSH_CUSTOM/plugins/ or ~/.oh-my-zsh/custom/plugins

Pluions can be added to the .zshrc file lile below

plugins=(git autojump zsh-autosuggestions zsh-syntax-highlighting)

Some plugins have to be installed before adding to the plugins array

brew install zsh-syntax-highlighting zsh-completions
brew install autojump

in case of issues

git clone https://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting

Follow the documentation for further instructions.

brew install timewarrior

iTerm-2 shortcuts

Shortcut For
⌘ , Open Preferences
⌘ D Split Windows Vertically
⌘ ⇧ D Split Windows Horizontally
⌘ ; Auto completion
⌘ ⇧ H Paste History
⌘ ⌥ B Show Interactive History
⌥ ⌘ Drag Select Rectangular Block

Once iTerm is set with above plugins, other terminals can simply be installed and with its corrosponding configs

Alacritty

https://www.josean.com/posts/how-to-setup-alacritty-terminal

https://www.josean.com/posts/7-amazing-cli-tools

WezTerm

https://www.josean.com/posts/how-to-setup-wezterm-terminal

References

Follow This Link

Follow this link as well

detailed link