Manage your dotfiles
Ah! Joys of configuration. All developer under Linux or Mac knows them. Even more if you are console addict like me. Configuration of Tmux, Vim, Zsh.... etc.
"OK, we know what are dotfiles. Get to the point?"The problems with the dotfiles are making them follow you on different workstation, how version them, etc...
"Can't you do that with git?"You can. And you should. So we make a
dotfilesrepository, we put our files in it and then it get .... boring. We have to link our files from our repository to our
$HOMEfolder. Some of us will make a script to make it automatically.
"OK, we get it, it's boring. Your solution?"
My solution is [dotbot](https://github.com/anishathalye/dotbot)! It's a tool which automate the linking of your files and more.
"Looks great, how do we use it?"
To use [dotbot](https://github.com/anishathalye/dotbot):
- first, create your repository:
mkdir dotfiles && git init
- add [dotbot](https://github.com/anishathalye/dotbot) as git sub module:
git submodule add https://github.com/anishathalye/dotbot
- copy the installation file provided by [dotbot](https://github.com/anishathalye/dotbot):
cp dotbot/tools/git-submodule/install .
- create your installation configuration:
- fill it up with your favorite editor:
- clean: - '~' - '~/.ssh' - '~/bin/' - link: ~/.gitconfig: dotfiles/gitconfig ~/.local.vim: dotfiles/local.vim ~/.SpaceVim: dotfiles/SpaceVim ~/.profile: dotfiles/profile
"How do you fill it?"
It's pretty simple:
linkwill define which to which place will be link the desire file. The element looks like
cleanwill clean up dead link in target directory. The element looks like that
For more information on how to use it, check the [README](https://github.com/anishathalye/dotbot/blob/master/README.md) of dotbot.
And I can't not show my dotfile, so check them [here](https://gitlab.deep-nope.me/mnivoliez/dotfiles).