Skip to content

yut23/zsh-homeshick

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

zsh dotfiles

I use homeshick for dotfile management, with my castles stored on GitHub (https://github.com/stars/yut23/lists/homeshick-castles).

I'm using GRML's zshrc as a base, with some minor modifications (mostly stripping out stuff I don't use).

Load sequence

The original file layout was inspired by https://github.com/seebi/zshrc, but has evolved considerably since I first started.

Common config files are stored in ~/.zsh/, while host-specific ones are in ~/.zsh/$system_name/ and are sourced immediately after the corresponding common ones.

  1. ~/.zshrc.pre
  2. extracts autotmux overrides out of $TERM (used later in ~/.zshrc.local, set by https://github.com/yut23/ssh-ident)
  3. adjusts GRML settings
  4. loads Zinit
  5. patches @zinit-scheduler to remove the chpwd hook
  6. ~/.zshrc (GRML)
  7. ~/.zshrc.local
  8. sets $HOSTNAME, with an optional override in ~/.hostname
  9. sources ~/.zsh/system_name.zsh to set $system_name, which determines what system I'm on for all host-specific configuration
  10. sources ~/.zsh/paths.zsh and ~/.zsh/$system_name/paths.zsh
  11. sources ~/.zsh/$system_name/modules.zsh if present and modules haven't been loaded before (modules.zsh can clear the loaded flag if needed)
  12. sources ~/.tmux/autotmux.zsh, which will exec into a shared tmux session if connected through ssh (or explicitly requested)
  13. loads homeshick
  14. sources all the other config files
  15. paths.zsh (loaded above)
  • sets up $PATH
  1. modules.zsh (loaded above)
  • loads any environment modules needed
  1. env.zsh
  2. aliases.zsh
  3. history.zsh
  4. misc.zsh
  5. plugins.zsh
  • zinit
  • prompt
  1. keys.zsh
  2. private.zsh

Conda/Mamba environments

  • conda init and mamba init code goes in per-system paths.zsh
  • activating the default environment is handled in plugins.zsh