Credit: hlissner/dotfiles
To keep up with my dotfiles.
I've learned a ton from keeping up with @hlissner's configs and use it as a technique to improve my own reasoning about software practices and develope my young opinions. Give them a read and while you're at it come check out Doom Emacs.
# Assumes your partitions are set up and root is mounted on /mnt
git clone https://github.com/emiller88/dotfiles /etc/dotfiles
USER=emiller HOST=meshify make -C /etc/dotfiles install
This is equivalent to:
DOTFILES=/home/$USER/.dotfiles
git clone https://github.com/emiller88/dotfiles $DOTFILES
ln -s /etc/dotfiles $DOTFILES
chown -R $USER:users $DOTFILES
# make channels
nix-channel --add "https://nixos.org/channels/nixos-${NIXOS_VERSION}" nixos
nix-channel --add "https://github.com/rycee/home-manager/archive/release-${NIXOS_VERSION}.tar.gz" home-manager
nix-channel --add "https://nixos.org/channels/nixpkgs-unstable" nixpkgs-unstable
# make /etc/nixos/configuration.nix
nixos-generate-config --root /mnt
echo "import /etc/dotfiles \"$$HOST\" \"$$USER\"" >/mnt/etc/nixos/configuration.nix
# make install
nixos-install --root /mnt -I "my=/etc/dotfiles"
make
=nixos-rebuild test
make switch
=nixos-rebuild switch
make upgrade
=nix-channel --update && nixos-rebuild switch
make install
=nixos-generate-config --root $PREFIX && nixos-install --root $PREFIX
make gc
=nix-collect-garbage -d
(use sudo to clear system profile)
- OS: NixOS 19.09
- Shell: zsh
- DE/WM: bspwm + polybar
- Editor: Doom Emacs (and occasionally [vim][vimrc])
- Terminal: st
- Browser: firefox (waiting for qutebrowser to mature)