Giter Club home page Giter Club logo

dotfiles's Introduction

My personal dotfiles

Importing the dotfiles

Taken from https://www.atlassian.com/git/tutorials/dotfiles

  1. Go to home directory and ignore the folder where you will clone the file
cd
echo "dotfiles" >> .gitignore
  1. Clone dotfiles into a bare repository in $HOME:
git clone --bare [email protected]:carlosluis/dotfiles.git $HOME/dotfiles
  1. In case you don't have it in .bashrc, go to the file add this line to define the alias:
alias dotfiles='/usr/bin/git --git-dir=$HOME/dotfiles/ --work-tree=$HOME'
  1. Source your changes
source ~/.bashrc
  1. Checkout the actual content from the bare repository into $HOME
dotfiles checkout
  1. Set the flag showUntrackedFIles to no on this local repo
dotfiles config --local status.showUntrackedFiles no

Modifying the dotfiles and commiting the changes

Let's say you modified the .bashrc file and want to commit the change

  1. Go to $HOME and verify the status of the dotfiles repo
cd
dotfiles status
  1. You can now verify all your unstaged changes and perform regulat git operations but using the dotfiles alias. Example: dotfiles diff will show you the diff of the tracked changes. To commit the changes:
dotfiles add .bashrc
dotfiles commit -m "minor change to .bashrc"
  1. Push the changes upstream
dotfiles push

Note

if you want to add a new file to the dotfiles (and start tracking its changes), you can simply do

dotfiles add <currently untracked file>

and commit/push.

dotfiles's People

Contributors

carlosluis avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.