Skip to content

PossessedC0bra/.dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

.dotfiles

This repo contains various config files. It follows the methodology describe by StreakyCobra over on Hacker News.

Initial setup

  1. Initialize a bare git repo with name .dotfiles
git init --bare $HOME/.dotfiles
  1. Add command alias to .aliases
echo "alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'" >> $HOME/.aliases && . ~/.zshrc
  1. Make git only show tracked files (untracked files can still be viewed with git status -u)
dotfiles config --local status.showUntrackedFiles no
  1. Adding this repository as upstream
dotfiles remote add origin https://github.com/PossessedC0bra/.dotfiles.git
  1. Creating main branch
git checkout main

Usage

Because the dotfiles command is simply an alias to the git command with default values we can simplt use it in place of the git command.

Examples

dotfiles status
dotfiles add .zshrc
dotfiles commit -m "feat: add .zshrc"
dotfiles push

Setup on a new computer

  1. Cloning this repository
git clone --bare https://github.com/PossessedC0bra/.dotfiles.git $HOME/.dotfiles
  1. Defining dotfiles alias in current shell for convenience
alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
  1. Checking out this repository
dotfiles checkout

About

My personal collection of config files for various programs

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors