.files
People insisted that I make one of these, so here we are.
Structure
I try to keep the dot clutter at a minimum within $HOME
, so I
make use of XDG base directory specs to shove away config files
elsewhere.
I defined $XDG_CONFIG_HOME
(~/.config
by default) to be
~/etc
and $XDG_DATA_HOME
(~/.local/share
by default) to be
~/usr/share
, so as to resemble hier(7)
a bit. (Note that some
odd applications actually hardcode ~/.config
or ~/.local/share
for some godforsaken reason.)
$XDG_DATA_HOME
shouldn’t be used to store any config. If it does,
it’s because the program dumps everything into a single directory
and its home was most likely set as an environment variable.
Similarly, certain programs are guilty of storing data and logs in
$XDG_CONFIG_HOME
.
These definitions are exported in zshenv
and I try to force
programs to use these dirs as much as possible with either
environment variables or with command-line options, although I try
to avoid the latter solution, as it leads to dangerous amounts of
kludge.
I hard linked my config files wherever possible (I just copied over
those carrying private info and edited away the sensitive parts,
and yes, the links get broken with each file update) for
convenience and preserved the hierarchy within my $HOME
except
for removing the dot prefix from filenames for clarity. Only
.git
, README.org
and .dir-locals.el
don’t actually exist in
my $HOME
.
Due to the immense amount of cruft in my config files (some of which weren’t altered since early 2011), I try to keep a bare workable minimum here. Send me a patch if you know how to (cleanly) move one of the top-level dotfiles into a config directory.
Until then, I’ll write up a solution with rewritefs instead. direnv is another viable solution.
emacs
These files are sourced in init.el
but aren’t included here:
custom.el
: It’s automatically rewritten too often to keep track of. Not like it contains anything of interest.private.el
: Only contains stuff like e-mail/usenet config and credentials for things like Mastodon.
zsh
As you probably noticed above, zsh config is neatly tucked into
etc/zsh
. This shouldn’t be possible, as zsh itself needs to
be told where the $ZDOTDIR
is in .zshenv
, but there’re zero
(0) profile related files in $HOME
at the top-level. The
solution is a little hack where you export $ZDOTDIR
as
$HOME/etc/zsh
in /etc/zsh/zshenv
. It works perfectly for me,
but your mileage may vary.
(zsh dotfiles must begin with a .
regardless of your
$ZDOTDIR
.)
Plugins
(I don’t use oh-my-zsh.)
Wallpapers
I’m very fond of tiling wallpapers. The archive I’ve accumulated over time can be accessed here.
FAQ
this XKB layout?
What’sStandard Dvorak with loads of level3/level4 keys. You can find it here.
Can I steal these?
People actually asked me this for some reason, and my answer is: Absolutely, go nuts. I don’t even want attribution for this mess. In fact, I stole a portion of these from others myself to begin with.
Acknowledgements
I would like to thank grawity
and earnestly
from Arch Linux IRC
channel for helping me strive for a cleaner $HOME
.