This document serves as a guide for how I customize my macOS and Linux terminals. It includes a variety of configurations, settings, and programs that I find useful for my daily workflow. The document is divided into several sections, each focusing on a different aspect of terminal customization.
NOTICE
If you view this document on GitHub or as a standard markdown file, you will not see the interactive elements, such as the details and tabs. To view the document in its entirety, please visit the website.
Useful Programs
The following table contains a list of terminal programs that I find particularly useful. These programs are separated into two categories: Third Party Package Managers (TPPM) and Native Package Managers (NPM).
The Third Party Package Managers section includes programs not installed using the system's default package manager. These programs are typically installed using tools like Homebrew, Pip, Cargo, Npm, Gem, or Git. I've included a brief description of each program and the relevant package manager(s) that can install it.
Git Installations
While most of these programs can be installed via git, they will not be marked as such unless recommended by the program's documentation or myself, or if it's the only other way to install the program.
The Native Package Managers section includes programs that can be installed using the system's default package manager. Since the primary Linux distributions I use are Debian based, all of the programs in this section are confirmed installable via apt. For other Linux distributions, you can check Repology to see if the program is available in your distribution's package manager. Like with TPPM, I've included a brief description for each program and a link with the number of repository families featuring the package.
Git is a fast, scalable, distributed revision control system with an unusually rich command set that provides both high-level operations and full access to internals.
Use ImageMagick® to create, edit, compose, or convert digital images. It can read and write images in a variety of formats (over 200) including PNG, JPEG, GIF, WebP, HEIC, SVG, PDF, DPX, EXR and TIFF.
Git is a fast, scalable, distributed revision control system with an unusually rich command set that provides both high-level operations and full access to internals.
Use ImageMagick® to create, edit, compose, or convert digital images. It can read and write images in a variety of formats (over 200) including PNG, JPEG, GIF, WebP, HEIC, SVG, PDF, DPX, EXR and TIFF.
Yes magick
More info here. Recommended install method: Homebrew.
Not a command. Zsh must be installed. Recommended install method: Git.
Customizing ZSH Shell
Framework
Oh-my-zsh is my preferred framework due to its popularity, reliability, and consistent updates. As one of the leading zsh frameworks, it made its initial commit on August 23, 2009, allowing it enough time to develop and refine its features.
Below is a list of oh-my-zsh plugins that I use and find to provide useful functionality.
Shell Theme
In combination with oh-my-zsh, I use Powerlevel10k as my shell theme. It's highly configurable and very appealing to the eyes.
ZSH Resource File
Below are tshe configurations for my .zshrc file, divided into two sections: macOS and Linux. The macOS configurations are tailored for macOS, while the other is designed for Linux.
You are welcome to use this resource in any manner you prefer. My intention is to offer it as a guide for structuring your own .zshrc file and to present additional configurations not detailed elsewhere in this document.
# CodeWhisperer pre block. Keep at the top of this file.[[-f"${HOME}/Library/Application Support/codewhisperer/shell/zshrc.pre.zsh"]]&&builtinsource"${HOME}/Library/Application Support/codewhisperer/shell/zshrc.pre.zsh"# If PowerLevel10K's Instant Prompt is enabled, `export GPG_TTY=$(tty)` needs to be# placed at the top of this file. Find more information here:# https://unix.stackexchange.com/questions/608842/zshrc-export-gpg-tty-tty-says-not-a-tty/608921#608921exportGPG_TTY=$(tty)# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.# Initialization code that may require console input (password prompts, [y/n]# confirmations, etc.) must go above this block; everything else may go below.if[[-r"${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"]];thensource"${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"fi# Path to your oh-my-zsh installation.exportZSH="$HOME/.oh-my-zsh"# Set name of the theme to load --- if set to "random", it will# load a random theme each time oh-my-zsh is loaded, in which case,# to know which specific one was loaded, run: echo $RANDOM_THEME# See https://github.com/ohmyzsh/ohmyzsh/wiki/ThemesZSH_THEME="powerlevel10k/powerlevel10k"# Uncomment the following line to use case-sensitive completion.# CASE_SENSITIVE="true"# Uncomment the following line to use hyphen-insensitive completion.# Case-sensitive completion must be off. _ and - will be interchangeable.# HYPHEN_INSENSITIVE="true"# Uncomment the following line if pasting URLs and other text is messed up.# DISABLE_MAGIC_FUNCTIONS=true# Uncomment the following line to enable command auto-correction.# ENABLE_CORRECTION="true"# Uncomment the following line if you want to change the command execution time# stamp shown in the history command output.# You can set one of the optional three formats:# "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"# or set a custom format using the strftime function format specifications,# see 'man strftime' for details.HIST_STAMPS="yyyy-mm-dd"# Which plugins would you like to load?# Standard plugins can be found in ~/.oh-my-zsh/plugins/*# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/# Example format: plugins=(rails git textmate ruby lighthouse)# Add wisely, as too many plugins slow down shell startup.plugins=(colored-man-pagescopybuffercopypathcopyfilebgnotify)# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-completions ${ZSH_CUSTOM:-${ZSH:-~/.oh-my-zsh}/custom}/plugins/zsh-completionszsh_completion="${ZSH_CUSTOM:-${ZSH:-~/.oh-my-zsh}/custom}/plugins/zsh-completions/src"[[-d$zsh_completion]]&&fpath+=${zsh_completion}source"$ZSH/oh-my-zsh.sh"####[ Personal Configurations ]#############################################################[[ Aliases ]]###########################################################################[[[ Group 1 ]]]####################################################################### General aliases.aliasic="cd ~/Library/Mobile\ Documents/com~apple~CloudDocs"aliasedisk="cd /Volumes && ll"aliaszls="eza"aliasrmdsstore="find . -name '*.DS_Store' -type f -delete"aliascode="open -a 'Visual Studio Code.app' ."aliasformatc="find . -name '*.cs' -type f -exec clang-format --style=file:~/Programs/Mine/Formatter\ Configs/CSharp_clang-format/_clang-format -i {} +"## Update based aliases.aliasupdatezshplugins="bash ~/Programs/mass-git/mass-git -p ~/.oh-my-zsh/custom/plugins/ -r"aliasupdatecopilot="bash ~/Programs/mass-git/mass-git -p ~/.config/nvim/pack/github/ -r"aliasupdatebrew="brew update && brew upgrade && brew autoremove && brew cleanup && brew doctor"aliasupdateomz="omz update"aliasupdateall="updatebrew; updateomz; updatecopilot; updatezshplugins"## GNU command aliases.aliascp="gcp"aliasmv="gmv"####[[[ Group 2 ]]]######################################################################### Due to the number of commands that I find to be useful, I've created aliases#### containing some of these commands. They are specifically commands that I don't#### often use, but are useful to have on hand. Having these aliases allows me to see#### a list of these commands, without having to commit them to memeory.aliaslt="echo -e \"####[ Package Manager installed commands ]##############################################bandwhich - Terminal bandwidth utilization tool.bat - A cat(1) clone with wings.codespell - Check code for common misspellings.duf - Disk Usage/Free Utility - a better 'df' alternative.fzf - A command-line fuzzy finder.ncdu - ncdu (NCurses Disk Usage) is a curses-based version of the well-known 'du'.pstree - List processes as a tree.tmux - Terminal multiplexer.####[[ Grouped commands ]]##############################################################lt_conversion - List of programs used for converting the formats of videos, images, etc.lt_git - List of programs used for git related commands.####[ Keyboard combinations ]###########################################################Ctrl + O - Allows you to copy what you are currently typing, via 'Ctrl' + 'O'.\""aliaslt_conversion="echo -e \"############################################################################################ [ Image and video formatters ]ffmpeg - FFmpeg is a collection of libraries and tools to process multimedia content.magick - Convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.\""aliaslt_git="echo -e \"####[ Git Related Commands ]###########################################################lazygit - Simple terminal UI for git commands.git open - Opens the GitHub page for a repo/branch in your browser.ugit - ugit helps you undo git commands without much effort.\""####[[[ SSH related commands ]]]########################################################aliashthompson="ssh -p 16449 hunter@143.198.55.59"aliasvoidtech="ssh ranger@135.181.75.52"####[[ Environmental Variables ]]######################################################## 1Password auth socket.exportSSH_AUTH_SOCK="$HOME/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"## NVM setup...exportNVM_DIR="$HOME/.nvm"[-s"/usr/local/opt/nvm/nvm.sh"]&&\."/usr/local/opt/nvm/nvm.sh"# This loads nvm[-s"/usr/local/opt/nvm/etc/bash_completion.d/nvm"]&&\."/usr/local/opt/nvm/etc/bash_completion.d/nvm"# This loads nvm bash_completion# Path purpose:# /usr/local/opt/curl/bin: ...# /usr/local/sbin: ???# /usr/local/opt/openjdk@17/bin: Prefered java version.# /usr/local/opt/node@18/bin: Prefered node version.exportPATH="/usr/local/opt/curl/bin:/usr/local/sbin:/usr/local/opt/openjdk@17/bin:/usr/local/opt/node@18/bin:$PATH"# Modifies colors of files and directories when using `ls`.exportLSCOLORS="exgxfxDxcxegDaabagacaD"## Version of LSCOLORS compatible with zsh and GNU based commands.## You can find more information about LS_COLORS and why it's needed in addition to LSCOLORS,## here: https://github.com/ohmyzsh/ohmyzsh/issues/6060#issuecomment-327934559exportLS_COLORS="di=34:ln=36:so=35:pi=1;33:ex=32:bd=34;46:cd=1;33;40:su=30;41:sg=30;46:tw=30;42:ow=30;1;43"## Editor configurations.exportEDITOR=nvim
exportVISUAL=$EDITOR####[[ Sourced Files ]]################################################################## To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.[[!-f~/.p10k.zsh]]||source~/.p10k.zsh
# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlightingzsh_syntax_highlighting="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"[[-f$zsh_syntax_highlighting]]&&source"$zsh_syntax_highlighting"# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestionszsh_autosuggestions="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh"[[-f$zsh_autosuggestions]]&&source"$zsh_autosuggestions"# Zsh "plugin" installed via git and the following command:# git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tabfzf_tab="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tab/fzf-tab.plugin.zsh"[[-f$fzf_tab]]&&hashfzf2>/dev/null&&source"$fzf_tab"# Enable the use of '1password-cli' plugins.source"$HOME/.config/op/plugins.sh"####[[ Zsh Style Configurations ]]####################################################### Disable sort when completing `git checkout`.zstyle':completion:*:git-checkout:*'sortfalse# Set descriptions format to enable group support.# NOTE: Don't use escape sequences here, fzf-tab will ignore them.zstyle':completion:*:descriptions'format'[%d]'# Set list-colors to enable filename colorizing.zstyle':completion:*'list-colors${(s.:.)LS_COLORS}## Preview directory's content with `eza` when completing `cd`.hasheza2>/dev/null\&&zstyle':fzf-tab:complete:cd:*'fzf-preview'eza -1 --color=always $realpath'# Switch group using `<` and `>`.zstyle':fzf-tab:*'switch-group'<''>'####[[ Others ]]############################################################################ These are generally configurations set up by setup scripts or other programs.# CodeWhisperer post block. Keep at the bottom of this file.[[-f"${HOME}/Library/Application Support/codewhisperer/shell/zshrc.post.zsh"]]&&builtinsource"${HOME}/Library/Application Support/codewhisperer/shell/zshrc.post.zsh"
# If PowerLevel10K's Instant Prompt is enabled, `export GPG_TTY=$(tty)` needs to be# placed at the top of this file. Find more information here:# https://unix.stackexchange.com/questions/608842/zshrc-export-gpg-tty-tty-says-not-a-tty/608921#608921exportGPG_TTY=$(tty)# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.# Initialization code that may require console input (password prompts, [y/n]# confirmations, etc.) must go above this block; everything else may go below.if[[-r"${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"]];thensource"${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"fi# Path to your oh-my-zsh installation.exportZSH="$HOME/.oh-my-zsh"# Set name of the theme to load --- if set to "random", it will# load a random theme each time oh-my-zsh is loaded, in which case,# to know which specific one was loaded, run: echo $RANDOM_THEME# See https://github.com/ohmyzsh/ohmyzsh/wiki/ThemesZSH_THEME="powerlevel10k/powerlevel10k"# Uncomment the following line to use case-sensitive completion.# CASE_SENSITIVE="true"# Uncomment the following line to use hyphen-insensitive completion.# Case-sensitive completion must be off. _ and - will be interchangeable.# HYPHEN_INSENSITIVE="true"# Uncomment the following line if pasting URLs and other text is messed up.# DISABLE_MAGIC_FUNCTIONS=true# Uncomment the following line to enable command auto-correction.# ENABLE_CORRECTION="true"# Uncomment the following line if you want to change the command execution time# stamp shown in the history command output.# You can set one of the optional three formats:# "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"# or set a custom format using the strftime function format specifications,# see 'man strftime' for details.HIST_STAMPS="yyyy-mm-dd"# Which plugins would you like to load?# Standard plugins can be found in $ZSH/plugins/# Custom plugins may be added to $ZSH_CUSTOM/plugins/# Example format: plugins=(rails git textmate ruby lighthouse)# Add wisely, as too many plugins slow down shell startup.#plugins=(git colored-man-pages copybuffer copypath copyfile bgnotify) # Desktopplugins=(gitcolored-man-pages)# Server# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-completions ${ZSH_CUSTOM:-${ZSH:-~/.oh-my-zsh}/custom}/plugins/zsh-completionszsh_completion="${ZSH_CUSTOM:-${ZSH:-~/.oh-my-zsh}/custom}/plugins/zsh-completions/src"[[-d$zsh_completion]]&&fpath+=${zsh_completion}source"$ZSH/oh-my-zsh.sh"####[ Personal Configurations ]#############################################################[[ Aliases ]]###########################################################################[[[ Group 1 ]]]####################################################################### General aliases.aliaszls="eza"## Update based aliases.aliasupdatezshplugins="bash ~/Programs/mass-git/mass-git -p ~/.oh-my-zsh/custom/plugins/ -r"aliasupdatecopilot="bash ~/Programs/mass-git/mass-git -p ~/.config/nvim/pack/github/ -r"aliasupdateapt="sudo apt update && sudo apt upgrade -y && sudo apt autoremove -y"aliasupdateomz="omz update"aliasupdateall="updateapt; updateomz; updatecopilot; updatezshplugins"####[[[ Group 2 ]]]######################################################################### Due to the number of commands that I find to be useful, I've created aliases#### containing some of these commands. They are specifically commands that I don't#### often use, but are useful to have on hand. Having these aliases allows me to see#### a list of these commands, without having to commit them to memeory.aliaslt="echo -e \"####[ Package Manager installed commands ]##############################################bandwhich - Terminal bandwidth utilization tool.bat - A cat(1) clone with wings.cheat - Allows you to create and view interactive cheatsheets on the command-line.codespell - Check code for common misspellings.duf - Disk Usage/Free Utility - a better 'df' alternative.fzf - A command-line fuzzy finder.ncdu - ncdu (NCurses Disk Usage) is a curses-based version of the well-known 'du'.pstree - List processes as a tree.tmux - Terminal multiplexer.####[[ Grouped commands ]]##############################################################lt_conversion - List of programs used for converting the formats of videos, images, etc.lt_git - List of programs used for git related commands.####[ Keyboard combinations ]###########################################################Ctrl + O - Allows you to copy what you are currently typing, via 'Ctrl' + 'O'.\""aliaslt_conversion="echo -e \"############################################################################################ [ Image and video formatters ]ffmpeg - FFmpeg is a collection of libraries and tools to process multimedia content.magick - Convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.\""aliaslt_git="echo -e \"####[ Git Related Commands ]###########################################################lazygit - Simple terminal UI for git commands.git open - Opens the GitHub page for a repo/branch in your browser.ugit - ugit helps you undo git commands without much effort.\""####[[ Environmental Variables ]]######################################################### Modifies the colors of files and directories in the terminal.exportLS_COLORS="di=34:ln=36:so=35:pi=1;33:ex=32:bd=34;46:cd=1;33;40:su=30;41:sg=30;46:tw=30;42:ow=30;1;43"# This is set in the Zsh Style Configurations section.#zstyle ':completion:*:default' list-colors ${(s.:.)LS_COLORS}# PATH value...exportPATH="$PATH:$HOME/.local/bin"####[[ Sourced Files ]]################################################################## To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.[[!-f~/.p10k.zsh]]||source~/.p10k.zsh
# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlightingzsh_syntax_highlighting="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh"[[-f$zsh_syntax_highlighting]]&&source"$zsh_syntax_highlighting"# Zsh "plugin" installed via git and the following command:# git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestionszsh_autosuggestions="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh"[[-f$zsh_autosuggestions]]&&source"$zsh_autosuggestions"# Zsh "plugin" installed via git and the following command:# git clone https://github.com/Aloxaf/fzf-tab ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tabfzf_tab="${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/fzf-tab/fzf-tab.plugin.zsh"[[-f$fzf_tab]]&&hashfzf2>/dev/null&&source"$fzf_tab"####[[ Zsh Style Configurations ]]####################################################### Disable sort when completing `git checkout`.zstyle':completion:*:git-checkout:*'sortfalse# Set descriptions format to enable group support.# NOTE: Don't use escape sequences here, fzf-tab will ignore them.zstyle':completion:*:descriptions'format'[%d]'# Set list-colors to enable filename colorizing.zstyle':completion:*'list-colors${(s.:.)LS_COLORS}## Preview directory's content with `eza` when completing `cd`.hasheza2>/dev/null\&&zstyle':fzf-tab:complete:cd:*'fzf-preview'eza -1 --color=always $realpath'# Wwitch group using `<` and `>`.zstyle':fzf-tab:*'switch-group'<''>'####[[ Others ]]############################################################################ These are generally configurations set up by setup scripts or other programs.
Oh-my-zsh Plugins
This is a list of all the oh-my-zsh plugins that I use and find to provide useful functionality.
Below is a list of aliases that are in my .zshrc files. They are broken up into two groups: Group 1 and Group 2. Group 1 contains general aliases, while Group 2 contains aliases listing categorized commands. Most of these commands are programs mentioned in Useful Programs, that I don't frequently use, but still want to have quick access to.
####[[ Aliases ]]###########################################################################[[[ Group 1 ]]]####################################################################### General aliases.aliasic="cd ~/Library/Mobile\ Documents/com~apple~CloudDocs"aliasedisk="cd /Volumes && ll"aliaszls="eza"aliasrmdsstore="find . -name '*.DS_Store' -type f -delete"aliascode="open -a 'Visual Studio Code.app' ."aliasformatc="find . -name '*.cs' -type f -exec clang-format --style=file:~/Programs/Mine/Formatter\ Configs/CSharp_clang-format/_clang-format -i {} +"## Update based aliases.aliasupdatezshplugins="bash ~/Programs/mass-git/mass-git -p ~/.oh-my-zsh/custom/plugins/ -r"aliasupdatecopilot="bash ~/Programs/mass-git/mass-git -p ~/.config/nvim/pack/github/ -r"aliasupdatebrew="brew update && brew upgrade && brew autoremove && brew cleanup && brew doctor"aliasupdateomz="omz update"aliasupdateall="updatebrew; updateomz; updatecopilot; updatezshplugins"## GNU command aliases.aliascp="gcp"aliasmv="gmv"####[[[ Group 2 ]]]######################################################################### Due to the number of commands that I find to be useful, I've created aliases#### containing some of these commands. They are specifically commands that I don't#### often use, but are useful to have on hand. Having these aliases allows me to see#### a list of these commands, without having to commit them to memeory.aliaslt="echo -e \"####[ Package Manager installed commands ]##############################################bandwhich - Terminal bandwidth utilization tool.bat - A cat(1) clone with wings.codespell - Check code for common misspellings.duf - Disk Usage/Free Utility - a better 'df' alternative.fzf - A command-line fuzzy finder.ncdu - ncdu (NCurses Disk Usage) is a curses-based version of the well-known 'du'.pstree - List processes as a tree.tmux - Terminal multiplexer.####[[ Grouped commands ]]##############################################################lt_conversion - List of programs used for converting the formats of videos, images, etc.lt_git - List of programs used for git related commands.####[ Keyboard combinations ]###########################################################Ctrl + O - Allows you to copy what you are currently typing, via 'Ctrl' + 'O'.\""aliaslt_conversion="echo -e \"############################################################################################ [ Image and video formatters ]ffmpeg - FFmpeg is a collection of libraries and tools to process multimedia content.magick - Convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.\""aliaslt_git="echo -e \"####[ Git Related Commands ]###########################################################lazygit - Simple terminal UI for git commands.git open - Opens the GitHub page for a repo/branch in your browser.ugit - ugit helps you undo git commands without much effort.\""
####[[ Aliases ]]###########################################################################[[[ Group 1 ]]]####################################################################### General aliases.aliaszls="eza"## Update based aliases.aliasupdatezshplugins="bash ~/Programs/mass-git/mass-git -p ~/.oh-my-zsh/custom/plugins/ -r"aliasupdatecopilot="bash ~/Programs/mass-git/mass-git -p ~/.config/nvim/pack/github/ -r"aliasupdateapt="sudo apt update && sudo apt upgrade -y && sudo apt autoremove -y"aliasupdateomz="omz update"aliasupdateall="updateapt; updateomz; updatecopilot; updatezshplugins"####[[[ Group 2 ]]]######################################################################### Due to the number of commands that I find to be useful, I've created aliases#### containing some of these commands. They are specifically commands that I don't#### often use, but are useful to have on hand. Having these aliases allows me to see#### a list of these commands, without having to commit them to memeory.aliaslt="echo -e \"####[ Package Manager installed commands ]##############################################bandwhich - Terminal bandwidth utilization tool.bat - A cat(1) clone with wings.cheat - Allows you to create and view interactive cheatsheets on the command-line.codespell - Check code for common misspellings.duf - Disk Usage/Free Utility - a better 'df' alternative.fzf - A command-line fuzzy finder.ncdu - ncdu (NCurses Disk Usage) is a curses-based version of the well-known 'du'.pstree - List processes as a tree.tmux - Terminal multiplexer.####[[ Grouped commands ]]##############################################################lt_conversion - List of programs used for converting the formats of videos, images, etc.lt_git - List of programs used for git related commands.####[ Keyboard combinations ]###########################################################Ctrl + O - Allows you to copy what you are currently typing, via 'Ctrl' + 'O'.\""aliaslt_conversion="echo -e \"############################################################################################ [ Image and video formatters ]ffmpeg - FFmpeg is a collection of libraries and tools to process multimedia content.magick - Convert between image formats as well as resize an image, blur, crop, despeckle, dither, draw on, flip, join, re-sample, and much more.\""aliaslt_git="echo -e \"####[ Git Related Commands ]###########################################################lazygit - Simple terminal UI for git commands.git open - Opens the GitHub page for a repo/branch in your browser.ugit - ugit helps you undo git commands without much effort.\""
Modifying CLI Colors
The terminal colors that are used for folders, files, and other items in the command line interface can be customized using the LS_COLORS (macOS & Linux) and LSCOLORS (macOS) environment variables. If you want to modify these colors, you can do so by setting the LS_COLORS or LSCOLORS variable in your .zshrc file.
LS_COLORS & LSCOLORS Explained
On macOS, both LSCOLORS and LS_COLORS are necessary for specifying terminal colors. LSCOLORS is used for commands like ls, determining the colors in the command line interface, whereas LS_COLORS is used by zsh for similar purposes. In contrast, Linux only requires LS_COLORS, which is employed by both the ls command and zsh.
The underlying reason for this difference lies in the distinct versions of the ls command on macOS (FreeBSD version) and Linux (GNU version). macOS's ls command relies on LSCOLORS for color settings, while Linux uses LS_COLORS, each with its unique formatting. Moreover, since zsh recognizes only the LS_COLORS format, it's imperative to use it on macOS to ensure proper display and functionality of CLI colors.
Included below is a key that explains the values of LSCOLORS and LS_COLORS in my configurations:
LSCOLORS
LS_COLORS
Type
Text Color
Foreground/Background Color
ex
di=34
Directories
blue
default
gx
ln=36
Symbolic link
cyan
default
fx
so=35
Socket
magenta
default
Dx
pi=1;33
Pipe
bold yellow
default
cx
ex=32
Executable
green
default
eg
bd=34;46
Block special
green
cyan
Da
cd=1;33;40
Character special
bold yellow
black
ab
su=30;41
Executable with setuid bit set
black
red
ag
sg=30;46
Executable with setgid bit set
black
cyan
ac
tw=30;42
Directory writeable to others (with a sticky bit)
black
green
aD
ow=30;1;43
Directory writeable to others (without sticky bit)
black
bold yellow
For an in-depth understanding of LS_COLORS and LSCOLORS, I recommend visiting this gist.
Below are my configurations for both macOS and Linux systems. To apply these settings, simply insert the following code into your ~/.zshrc file:
# Modifies colors of files and directories when using `ls`.exportLSCOLORS="exgxfxDxcxegDaabagacaD"## Version of LSCOLORS compatible with zsh and GNU based commands.## You can find more information about LS_COLORS and why it's needed in addition to LSCOLORS,## here: https://github.com/ohmyzsh/ohmyzsh/issues/6060#issuecomment-327934559exportLS_COLORS="di=34:ln=36:so=35:pi=1;33:ex=32:bd=34;46:cd=1;33;40:su=30;41:sg=30;46:tw=30;42:ow=30;1;43"zstyle':completion:*:default'list-colors${(s.:.)LS_COLORS}
## Modifies the colors of files and directories in the terminal.exportLS_COLORS="di=34:ln=36:so=35:pi=1;33:ex=32:bd=34;46:cd=1;33;40:su=30;41:sg=30;46:tw=30;42:ow=30;1;43"zstyle':completion:*:default'list-colors${(s.:.)LS_COLORS}
You can additionally modify the shading and appearance of the CLI colors by adjusting the ANSI-color scheme in your terminal profile. This can be done manually, with guides available for both macOS and Linux (gnome specific instructions). Alternatively, you can use my custom profile schemes, which are detailed in the Terminal Profile section.
Neovim Resource File
Due to the extensibility and community of Neovim, I have chosen it as my primary text editor, favoring it over the traditional Vi or Vim. Below are the configurations for my init.vim file, which is located in the ~/.config/nvim/ directory. The configurations are divided into two sections: with and without vim-plug plugins.
With Vim-Plug Plugins
The following configurations modify the behavior and appearance of vim. To use these settings, you'll first need to install vim-plug, a plugin manager for vim. While other vim package managers can be used, the configurations are tailored specifically for vim-plug.
After installing vim-plug, copy the code below into your ~/.config/nvim/init.vim file. With init.vim open in nvim, initiate the plugin installation by entering :source % and :PlugInstall as separate commands. This will prompt vim-plug to begin the installation of the plugins outlined in the configurations below.
Note
When using :source %, you can ignore any errors that might occur, as they are (most likely) a result of nvim looking for the plugins that have yet to be installed.
Vim Plugin Information
Here is a list of all the plugins listed in init.vim, along with a description of what they do.
""""[ vim-plug Configurations ]"""""""""""""""""""""""""""""""""""""""""""""""""""""""""call plug#begin(stdpath('data') . '/plugged')" Make sure you use single quotes" Vim help for vim-plug itselfPlug 'junegunn/vim-plug'" Rainbow delimiters for Neovim with Tree-sitter.Plug 'HiPhish/rainbow-delimiters.nvim'" Lean & mean status/tabline for vim that's light as air.Plug 'vim-airline/vim-airline'" A collection of themes for vim-airline.Plug 'vim-airline/vim-airline-themes'" Retro groove color scheme for Vim.Plug 'sainnhe/gruvbox-material'" Check syntax in Vim asynchronously and fix files, with Language Server Protocol (LSP)" support.Plug 'dense-analysis/ale'" Better whitespace highlighting for Vim.Plug 'ntpeters/vim-better-whitespace'" An incremental parsing system for programming tools.Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
" Highlight columns in CSV and TSV files and run queries in SQL-like language.Plug 'mechatroner/rainbow_csv'" Initialize plugin systemcall plug#end()"" Brief help:" PlugInstall - Install plugins" PlugUpdate - Install or update plugins" PlugClean - Remove unlisted plugins (bang version will clean without prompt)" PlugUpgrade - Upgrade vim-plug itself" PlugStatus - Check the status of plugins" PlugDiff - Examine changes from the previous update and the pending changes" PlugSnapshot - Generate script for restoring the current snapshot of the plugins""""[ Non-vim-plug Related Configurations ]""""""""""""""""""""""""""""""""""""""""""""""" Overwrites specified default setting.settabstop=4" Tells vim how many columns a tab counts for.setshiftwidth=4" 'Levels of indentation', where a level of indentation is " shiftwidth columns of whitespace.setexpandtab" Ensure that when you hit tab it will actually use spaces.setcolorcolumn=88" Set a colored line at column 88 in every row."" Markdown filesautocmd Filetype markdown setlocalcolorcolumn=0"" TXT filesautocmd Filetype text setlocalcolorcolumn=0"" Javaautocmd Filetype java setlocalcolorcolumn=94"" C#autocmd Filetype cssetlocalcolorcolumn=120"" HTMLautocmd Filetype html setlocalcolorcolumn=100tabstop=2shiftwidth=2nowrap"" CSSautocmd Filetype css setlocalcolorcolumn=100tabstop=2shiftwidth=2nowrap"" Vueautocmd Filetype vue setlocalcolorcolumn=100tabstop=2shiftwidth=2""""[ vim-plug Plugin Configurations ]""""""""""""""""""""""""""""""""""""""""""""""""""" Font: Power Line Fontsetguifont=MesloLGS_NF:h12
"" Plugin: gruvbox-materialcolorscheme gruvbox-material
setbackground=darkletg:gruvbox_material_foreground ='original'letg:gruvbox_material_enable_bold =1letg:gruvbox_material_enable_italic =1"" Plugin: vim-airlineletg:airline#extensions#tabline#enabled =1letg:airline#extensions#tabline#left_sep =' 'letg:airline#extensions#tabline#left_alt_sep ='|'letg:airline#extensions#tabline#formatter ='default'letg:airline#extensions#ale#enabled =1letg:airline_powerline_fonts =1"" Plugin: better-whitespaceletg:better_whitespace_enabled =1letg:strip_whitespace_on_save =1"" Plugin: ale"let g:ale_use_neovim_diagnostics_api = 0""""[ Useful Commands ]"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" :NERDTree - Opens NERDTree file system explorer." :StripWhitespace - Clean extra whitespace." :ALEInfo - Show ALE information." :ALEToggle - Toggle ALE on/off." :TSInstall - Install treesitter parsers." :TSUpdate - Update treesitter parsers." :TSInstallInfo - Show treesitter information.
Without Vim-Plug Plugins
If you prefer not to use all the features offered by vim-plug, you can opt for a more basic setup by incorporating the configurations listed below into your .vimrc file. These adjustments modify certain default settings of vim without altering the core functionality, providing a simpler, more streamlined experience while maintaining the essence of vim's default behavior.
"" Overwrites specified default setting.settabstop=4" Tells vim how many columns a tab counts for.setshiftwidth=4" 'Levels of indentation', where a level of indentation is " shiftwidth columns of whitespace.setexpandtab" Ensure that when you hit tab it will actually use spaces.setcolorcolumn=88" Set a colored line at column 88 in every row."" Markdown filesautocmd Filetype markdown setlocalcolorcolumn=0"" TXT filesautocmd Filetype text setlocalcolorcolumn=0"" Javaautocmd Filetype java setlocalcolorcolumn=94"" C#autocmd Filetype cssetlocalcolorcolumn=120"" HTMLautocmd Filetype html setlocalcolorcolumn=100tabstop=2shiftwidth=2nowrap"" CSSautocmd Filetype css setlocalcolorcolumn=100tabstop=2shiftwidth=2nowrap"" Vueautocmd Filetype vue setlocalcolorcolumn=100tabstop=2shiftwidth=2
Neovim GitHub Copilot
...coming soon...
Installed TreeSitter Parsers
...coming soon...
Terminal Profile
My custom terminal profile is a modified version of the Basic profile that comes pre-installed on macOS. To add it to your list of profiles, follow the instructions below:
Download the terminal profile using the following link: Terminal Profile
Open a terminal window.
Click on Preferences... ==> Profiles ==> the gear icon at the bottom left of the window ==> Import... ==> locate and click on the 'Basic (Modified).terminal' tab
Click on the new terminal profile, then press the "Default" button located at the bottom of the window.
My custom terminal profile is a based on the Terminal Profile that I use on macOS. To add it to your list of profiles, follow the instructions below:
Download the terminal profile using the following link: Terminal Profile
Open a terminal window.
Enter the following command to import the profiles: dconf load /org/gnome/terminal/legacy/profiles:/ < LOCATION_OF_DOWNLOADED_FILE
Warning
Using the above dconf command will overwrite all existing profiles