This repository contains my custom configuration for the Ghostty terminal, including integration with Atuin for command history, Yazi as a file manager, and Mole for Mac cleaning and optimization.
The terminal configured with the Catppuccin Mocha theme, JetBrains Mono Nerd Font, and transparency/blur for a modern look.
Atuin lets you search and navigate through command history efficiently, with semantic search and execution statistics.
Yazi offers a modern file browsing experience directly in the terminal, with preview and intuitive navigation.
Mole is a CLI tool to deep clean and optimize your Mac, featuring system cleanup, smart app uninstalling, disk space analysis, live system monitoring, and project artifact cleanup.
Global shortcut Cmd+Esc to quickly open/close the terminal from any application.
- macOS (tested on macOS Sonoma/Ventura)
- Homebrew installed
- Git installed
brew install --cask ghosttyZsh usually comes pre-installed on macOS. To verify:
zsh --versionIf it's not installed or you want to update:
brew install zshsh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"git clone --depth=1 https://github.com/romkatv/powerlevel10k.git ${ZSH_CUSTOM:-$HOME/.oh-my-zsh/custom}/themes/powerlevel10kThen add to your ~/.zshrc:
source /opt/homebrew/share/powerlevel10k/powerlevel10k.zsh-themegit clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlightinggit clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestionsgit clone https://github.com/zsh-users/zsh-history-substring-search ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-history-substring-searchThe z, sudo, web-search, and copypath plugins are already included with Oh My Zsh.
Copy the contents of the provided .zshrc file or add the following configuration:
plugins=(
z
sudo
zsh-syntax-highlighting
web-search
copypath
zsh-autosuggestions
zsh-history-substring-search
)
export ZSH="$HOME/.oh-my-zsh"
source $ZSH/oh-my-zsh.sh
source /opt/homebrew/share/powerlevel10k/powerlevel10k.zsh-theme
# Bind keyboard shortcuts for zsh-history-substring-search
bindkey "$terminfo[kcuu1]" history-substring-search-up
bindkey "$terminfo[kcud1]" history-substring-search-downbrew install atuinIt can also be installed with the following command, as described in the Atuin documentation:
curl --proto '=https' --tlsv1.2 -LsSf https://setup.atuin.sh | shAdd to the end of your ~/.zshrc:
. "$HOME/.atuin/bin/env"
eval "$(atuin init zsh)"To sync your history across devices:
atuin register -u <your-username>
atuin login -u <your-username>And to sync your history with previously executed commands:
atuin import auto1. Update brew:
brew update2. Install dependencies:
brew install yazi ffmpeg sevenzip jq poppler fd ripgrep fzf zoxide resvg imagemagick font-symbols-only-nerd-font3. Install Yazi:
brew install yaziAdd this function to your ~/.zshrc to allow Yazi to change the current directory after closing:
function y() {
local tmp="$(mktemp -t "yazi-cwd.XXXXXX")"
yazi "$@" --cwd-file="$tmp"
if cwd="$(cat "$tmp")" && [ -n "$cwd" ] && [ "$cwd" != "$PWD" ]; then
builtin cd -- "$cwd"
fi
rm -f "$tmp"
}How it works:
- Creates a temporary file to store the current directory
- Opens Yazi with the temporary file as a reference
- When you close Yazi, it saves the selected directory to the temporary file
- The function reads that file and changes to the selected directory
- Removes the temporary file after use
Usage:
y # Opens Yazi in the current directory
y /path # Opens Yazi in a specific directoryMole is a CLI tool for deep cleaning and optimizing your Mac.
brew install moleIt can also be installed via the install script:
curl -fsSL https://raw.githubusercontent.com/tw93/mole/main/install.sh | bashKey features:
- Deep system cleanup (caches, logs, browser data)
- Smart app uninstaller with thorough removal of associated files
- System optimization (rebuilds databases, clears caches, refreshes services)
- Disk space analysis and large file identification
- Live system monitoring (CPU, memory, disk, network)
- Project artifact cleanup (node_modules, target, venv, etc.)
Usage:
moleCopy the config file to the Ghostty configuration directory:
mkdir -p "$HOME/Library/Application Support/com.mitchellh.ghostty"
cp config "$HOME/Library/Application Support/com.mitchellh.ghostty/config"Or clone this repository and create a symlink:
git clone <your-repository> ~/.config/ghostty
ln -s ~/.config/ghostty/config "$HOME/Library/Application Support/com.mitchellh.ghostty/config"The theme requires a Nerd Font. Install JetBrains Mono Nerd Font:
brew install --cask font-jetbrains-mono-nerd-font| Shortcut | Action |
|---|---|
Cmd + Esc |
Opens/closes the dropdown terminal (quick terminal) |
| Shortcut | Action |
|---|---|
Super + D |
Creates a vertical split (right) |
Super + Shift + D |
Creates a horizontal split (bottom) |
Super + Ctrl + H |
Moves to the left split |
Super + Ctrl + L |
Moves to the right split |
Super + Ctrl + K |
Moves to the split above |
Super + Ctrl + J |
Moves to the split below |
| Shortcut | Action |
|---|---|
Super + T |
Creates a new tab |
Super + W |
Closes the current surface (split/tab) |
Super + Alt + Right Arrow |
Next tab |
Super + Alt + Left Arrow |
Previous tab |
| Shortcut | Action |
|---|---|
Super + R |
Reloads the configuration |
Super + Ctrl + F |
Toggles fullscreen |
Note: Super refers to the Cmd key on macOS.
| Shortcut | Action |
|---|---|
Up Arrow |
Search history (substring search) |
Down Arrow |
Reverse history search |
| Shortcut | Action |
|---|---|
Ctrl + R |
Opens Atuin for history search |
Esc |
Closes Atuin |
Tab |
Edits the selected command |
Enter |
Executes the selected command |
Ctrl + O |
Inspects the history |
The repository includes a useful script to update the system and Homebrew packages.
- Make sure the script is executable:
chmod +x /Users/balvesdematos/Documents/script/update_mac.sh- The alias is already configured in
.zshrc:
alias update="/Users/balvesdematos/Documents/script/update_mac.sh"Simply run:
updateThe script will:
- Check for Homebrew updates
- Check for macOS updates
- Ask if you want to install the updates
- Run the updates according to your choice
The current theme is Catppuccin Mocha. To change it, edit the following line in the config file:
theme = Catppuccin MochaOther available themes can be found in the Ghostty documentation.
The default font is JetBrains Mono Nerd Font. To change it:
font-family = "Your Nerd Font"
font-size = 25Adjust opacity and blur in the config file:
background-opacity = 0.8 # 0.0 (transparent) to 1.0 (opaque)
background-blur = 90 # Blur intensityMake sure Ghostty has accessibility permissions:
- Go to System Settings > Privacy & Security > Accessibility
- Add Ghostty to the list of allowed applications
Check that Atuin is installed and initialized:
atuin --version
atuin infoIf necessary, reinitialize the shell:
exec zshMake sure the y() function is in your .zshrc and that you're using y instead of yazi directly.
Check that the plugins are installed in the correct directories:
ls ~/.oh-my-zsh/custom/plugins/And make sure they're listed in the plugins array in .zshrc.
This repository contains only personal configurations. Feel free to use and adapt them to your needs.
Suggestions and improvements are welcome! Feel free to open an issue or pull request.




