Cookiecutter template for dotfile projects.
These projects are generated that the actual files stay in the generated dotfile directory, and are managed using stow, which creates matching links in the target path (usually
cookiecutter command line:
pip install cookiecutter
Generate a new Cookiecutter template layout:
cookiecutter gh:bdcaf/cookiecutter_dotfile. See the generated Readme.md for further instructions.
stow-local-ignoreis essential to keep your documentation and other local files out of the config dir.
stowrcallows to configure options for stow
.gitignorekeeps temporary files out of git.
.gitkeepis a hack so as git will not store empty directories - they may be empty as all files inside were ignored. They will miss in cloned repos and some software gives you errors due to this. Best to create as an empty file with
touch .gitkeepin the correct location.
- Makefile uses
$itself - so to work with environment variables you need to add another
$- like the
$$HOMEin the default config.
- Makefile doesn't know about
$$HOMEto point to it.
- if you need to stow into multiple places you can add several lines like this
stow -v --target="$$HOME/.vim/" -S config
I use this to stow vim config (in folder
config) to both
~/.vim as well as
The trick is also handy if you don't like working with hidden directories.
a little warning
make runs commands in the
Makefile. Spend a little time familiarizing you with the code in there - bad people might hide malicious code in there. It could also be abused to exfiltrate data.
The code in the default
Makefile is reasonable simple - actually just one line doing anything (line 4) - and a few empty definitions. If you find one containing lots of code be wary.
This project is licensed under the terms of the MIT License