Skip to content

Dotfiles including zshrc, pryrc, setup scripts etc

Notifications You must be signed in to change notification settings

imamrb/dotfiles

Repository files navigation

Dotfiles ⚡

Setup scripts for mac: /Documents/MacSetup

Prerequisite

# 1. Install oh_my_zsh
   sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

# 2. Install zinit
   sh -c "$(curl -fsSL https://raw.githubusercontent.com/zdharma-continuum/zinit/HEAD/scripts/install.sh)"

Installing on a new machine

  • Clone the repository to ~/.dotfiles folder
  • Ignore the repo to avoid tracking itself
  • Define an alias named dotfiles which will work substitute git command
  • Don't show untracked files in dotfiles status
  • Backup the existing files to .dotfiles-backup folder and replace them with newer ones.
  • Checkout the actual content from your .dotfiles repository to $HOME
   git clone --bare git@github.com:imamrb/dotfiles.git $HOME/.dotfiles

   alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
   dotfiles config --local status.showUntrackedFiles no
   mkdir -p .dotfiles-backup && \
   dotfiles checkout 2>&1 | egrep "\s+\." | awk {'print $1'} | \
   xargs -I{} mv {} .dotfiles-backup/{}
   dotfiles checkout

For Details Explanation of these commands, checkout this blog here.

Thanks to

About

Dotfiles including zshrc, pryrc, setup scripts etc

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published