shortcuts.md

🛠️ Dotfiles & Shell Master Cheatsheet

🚀 Core Workflow & Synchronization

Action Command Description
Update System update Pulls dotfiles, updates Vim plugins, re-stows configs, and reloads shell.
Snapshot snapshot Full backup of Brewfile, SSH/GPG, Fish, Zsh, and Vim configs to Git.
Fix Links stow --adopt -v -R . Manually re-links dotfiles using GNU Stow.
Reload Shell reload Sources your config file to apply changes immediately.

🐚 Shell Abbreviations & Modern Tools

These tools provide an enhanced terminal experience across Mac and VPS.

Abbr Command Description
ls / ll eza List files with icons, grid views, and git integration.
cat bat Syntax-highlighted file viewing.
cd zoxide Smart directory jumping (aliased to z or cd).
md glow -p Render Markdown files in the terminal.
gs git status Quick check of repository status.
conf vim <config> Edit your config.fish or .zshrc.
f open . Open current directory in Finder (Mac) or File Explorer (Linux).
cppath pwd | clip Copies current absolute path to the system clipboard.

🔑 Security: SSH & YubiKey

Diagnostics

  • ssh-add -L: List all public keys/stubs currently loaded in your agent.
  • ssh -T git@github.com: Verify your GitHub connection via SSH.
  • ssh -v vps: Connect to your VPS with verbose output to debug identity files.
  • ykman list: List connected YubiKeys (requires ykman installed).
  • gpg --card-status: Check if the YubiKey OpenPGP application is detected.

GPG Signing

  • gpg --list-secret-keys --keyid-format LONG: Find your Key ID for Git config.
  • echo "test" | gpg --clearsign: Force a PIN prompt to verify communication.
  • git log --show-signature -1: Verify the signature of the most recent commit.

🎨 iTerm2 Badge Legend

The badge in the top-right corner of your terminal provides real-time system status.

[Image of iTerm2 status badges]

Git Status (Current Directory)

  • ⚪ (White): The current directory is not a Git repository.
  • 🟢 (Green): Git working tree is clean.
  • 🔴 (Red): Uncommitted changes detected in the current repository.

System Status (Dotfiles Repository)

  • 🛡️ (Shield): Your ~/dotfiles repository is clean and synced.
  • ⚠️ (Warning): Your ~/dotfiles repository has uncommitted changes. Run snapshot!

📝 Vim & Text Editing

Action Key / Command Description
Smart Load v Launches Vim; restores Session.vim if it exists.
Plugins :PlugUpdate Updates all Vim plugins via the configured manager