For further information, please refer to the NixOS documentation
First, install NixOS as it is recommended by the official documentation. If full disk encryption is required, read here for more information.
# Update channels
nix-channel update
# Update flake
nix flake update
# Update system
nixos-rebuild switch --flake '.#stefan' --upgrade
# Build Image
nix build .#vmnix-env -p /nix/var/nix/profiles/system --delete-generations old
nix-collect-garbage -d
nix-env -p /nix/var/nix/profiles/system --list-generations
## Remove entries from /boot/loader/entries:
sudo bash -c "cd /boot/loader/entries; ls | grep -v <current-generation-name> | xargs rm"Make sure flake is already available during set up otherwise it might fail.
To build a custom host, just copy a default one and adapt to your needs.
Important: install bootloader might fail, add --install-bootloader during NixOS build
Use extension i3 with i3 config to lint your profile:
"files.associations": {
"**/.i3/config": "i3",
"**/i3/config": "i3",
"**/i3/config/*": "i3",
},# Restart and reload
i3-msg reload
i3-msg restartMore information documentation
By default, I use a US layout. However, I need german umlauts so I added a custom layout. Only one problem is that I cannot set it as default. Please run:
setxkbmap usFor personal use, I have Canon printers like MF522. To add a printer please refer to the documentation
lpadmin -p Canon-XXXXX -E -v ipp://XXX.XXX.X.XX/ipp/print -m everywheretmui: configure Wifi connection
Set multilockscreen:
betterlockscreen -u ~/Documents/nixos-artwork/wallpapers/nix-wallpaper-nineish-dark-gray.svg --display 1 --span
betterlockscreen -u path_to_file --fx dim,pixelSet background:
nitrogen --no-recurse ~/Documents/git/nixos-artwork/wallpapersSet up new display:
# See what displays are available
xrandr
# Set display
xrandr --output DisplayPort-1 --auto --left-of eDP
# Save
autorandr --saveSet the font in the settings.json correctly:
{
"terminal.integrated.fontFamily": "'Source Code Pro for Powerline', 'Hack Nerd Font'"
}nitrogen: Change backgroundmultilockscreen: Lock i3
