I'm looking for a better way of managing my dot/configuration files across multiple environments.
What I'm Doing Currently
I've got a dotfiles git repo with some build-scripts that dynamically build files, detect the operating system, and fill in the templates accordingly. This works okay-ish. Sort of. It could be better. The downside is that I'm always making teeny tiny tweaks to my dotfiles (particularly my .vimrc
and .zshrc
files), and so the individual instances drift apart pretty quickly. This is driven by the fact that I always forget (read: am too lazy) to do "commit/push" after I make a small change, and "pull/build/deploy" whenever I sit down at a different workstation. So, I almost always end up re-writing the dotfile for any given new workstation from an obsolete version. Which is lame.
Features I'd Like
- A non-local central place to store my configuration files.
- A method of making them OS- or machine-specific. For example, I've got an alias on my Mac that aliases
rm
totrash
for a more ergonomic delete. I don't necessarily need this on a Linux server, and I definitely don't need it on a Windows machine. - Ideally, it should be able to handle tiny tweaks robustly, so that it syncs up after the change (or periodically) without me having to type a bunch of git commands.
- It would be nice if it was easy to deploy to a new, fresh machine. What this means is that if it uses a build or deploy script, that should run without having to install a bunch of stuff beforehand, since that kind of defeats the purpose. I'm currently using a Ruby script, but, as you might know, Ruby is anything but simple to set up and it's certainly not consistent across OS's.
- There are certain pieces (keys, usernames, etc.) that are needed to fully configure a machine, but I don't necessarily want to put those out in public. I'm not sure how to separate the secret/private stuff from the public stuff.
Anyways, I'm happy to implement as much custom scripting as needed. In fact, I super duper love it. I'm just looking for some ideas.