Skip to content

Instantly share code, notes, and snippets.

@ivangarzab
Last active February 10, 2026 01:49
Show Gist options
  • Select an option

  • Save ivangarzab/3850af4ca63fe088f74c84bf5acfeae4 to your computer and use it in GitHub Desktop.

Select an option

Save ivangarzab/3850af4ca63fe088f74c84bf5acfeae4 to your computer and use it in GitHub Desktop.
Terminal Setup
# ============================================
# Minimal zsh Configuration
# ============================================
# --- Basic zsh settings ---
setopt AUTO_CD # Type directory name to cd into it
setopt HIST_IGNORE_DUPS # Don't save duplicate commands in history
setopt SHARE_HISTORY # Share history across all terminals
HISTFILE=~/.zsh_history
HISTSIZE=10000
SAVEHIST=10000
# --- Initialize Starship Prompt ---
eval "$(starship init zsh)"
# --- Syntax Highlighting ---
if [ -f ~/.zsh-plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh ]; then
source ~/.zsh-plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh
fi
# --- Git Command Shortcuts ---
alias gs='git status'
alias gf='git fetch'
alias gc='git checkout'
alias gl='git log --oneline'
alias gup='git push -u origin'
alias gu='git submodule update --init --recursive'
alias gst='git stash'
alias gst-export='git stash show stash@{0} -p > changes.patch'
alias git-discard='git reset --hard @{u}'
alias gwhere='git remote -v'
# Git help - show all git aliases
alias git-help='cat << "EOF"
Git Aliases:
---------------------------------------------------------------
gs git status
gf git fetch
gc git checkout
gl git log --oneline
gup git push -u origin (set upstream and push)
gu git submodule update --init --recursive
gst git stash
gst-export git stash show stash@{0} -p > changes.patch
git-discard git reset --hard @{u} (discard local changes)
gwhere git remote -v (show remotes)
---------------------------------------------------------------
EOF
'
# --- Load Turo Configuration ---
# (includes NVM, SDKMAN, pyenv, tfenv, yarn - all lazy loaded)
source "$HOME/.turorc"
# --- Add local bin to PATH ---
export PATH="$HOME/.local/bin:$PATH"

Terminal Setup - Installation Guide

Quick setup guide for configuring your terminal on a new machine.

Prerequisites

  • macOS (or Linux with Homebrew installed)
  • Git

Installation Steps

1. Install Starship

brew install starship

2. Clone Syntax Highlighting Plugin

mkdir -p ~/.zsh-plugins
git clone https://github.com/zdharma-continuum/fast-syntax-highlighting ~/.zsh-plugins/fast-syntax-highlighting

3. Download Configuration Files

# Download .zshrc
curl https://gist.githubusercontent.com/ivangarzab/3850af4ca63fe088f74c84bf5acfeae4/raw/.zshrc > ~/.zshrc

# Create config directory if it doesn't exist
mkdir -p ~/.config

# Download starship.toml
curl https://gist.githubusercontent.com/ivangarzab/3850af4ca63fe088f74c84bf5acfeae4/raw/starship.toml > ~/.config/starship.toml

4. Restart Your Terminal

Close and reopen your terminal, or run:

source ~/.zshrc
# Starship Configuration
# Use custom color palette (defined at bottom)
palette = "custom"
# Format: ◀ directory[git_branch](git_status)▶ prompt...
format = """
[◀](bold primary) \
[](bold primary)\
[$directory](primary)\
$git_branch\
$git_status\
[▶](bold primary) \
$character"""
# Disable command duration by default
[cmd_duration]
disabled = true
# Character (the prompt symbol)
[character]
success_symbol = ""
error_symbol = ""
# Directory settings
[directory]
format = "[$path](bold $style)"
style = "primary"
truncation_length = 3
truncate_to_repo = true
# Git branch
[git_branch]
format = "[\\[[$branch](secondary)\\]]($style)"
style = "primary"
# Git status
# Shows only: 1) dirty working dir, 2) commits to push, 3) commits to pull, 4) conflicts
[git_status]
format = "([\\(](primary)[$conflicted$modified$staged$untracked$deleted$renamed$ahead_behind]($style)[\\)](primary))"
style = "primary"
modified = "⁑"
staged = "⁑"
untracked = "⁑"
deleted = "⁑"
renamed = "⁑"
conflicted = "[⚔](red)"
ahead = "[▲$count](blue)"
behind = "[▼$count](orange)"
diverged = "[▲$ahead_count](blue)[▼$behind_count](orange)"
# Color Palette
[palettes.custom]
primary = "#B19CD9" # lavender
secondary = "#FFDB58" # mustard yellow
tertiary = "#D1001C"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment