NixOS system configuration for my private machines
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Matthias Thym 20284e0494 Add hugin to graphics module 1 week ago
bin Fix spacing in rofi-power-menu 1 week ago
config Rework hyprland config 1 week ago
hosts Move systemd emergency mode option to disk module 1 week ago
lib How can this still be here 2 years ago
modules Add hugin to graphics module 1 week ago
overlays Rewrite to use flakes 2 years ago
packages Rewrite to use flakes 2 years ago
.gitignore Do not add ssh information 2 years ago
LICENSE Update copyright year 3 years ago Update to NixOS 22.05 Quokka 6 months ago Add cachix binary cache for hyprland 3 months ago
default.nix Switch to NixOS unstable 2 weeks ago
flake.lock Bump versions 1 week ago
flake.nix Switch to NixOS unstable 2 weeks ago
shell.nix 'nixFlakes' has been renamed to/replaced by 'nixVersions.stable' 1 month ago

Get it on Codeberg

NixOS 22.05

Commit activity Latest commit

Hey, you. You're finally awake. You were trying to configure your OS declaratively, right? Walked right into that NixOS ambush, same as us, and those dotfiles over there.

Note that this repository is a fork of Henrik Lissner's dotfiles which I have modified and updated over the years to better suit my needs.

In case you need help getting started with NixOS and want to use these dotfiles as a starting point, feel free to raise issues asking for help or send me an Email to my Git commit address which you can find on my profile.

Screenshots 4K Display

Full Desktop Floating Desktop

Shell: zsh + zgen
DM: lightdm + lightdm-mini-greeter
WM: bspwm + polybar
Editor: micro (and occasionally nvim)
Terminal: kitty
Launcher: rofi
Browser: firefox
GTK Theme: Ant Dracula

If you've never before installed NixOS, make sure to read through the official installation guide. This quick start guide is based on the installation instructions in the official NixOS manual so you might want to skim over them as well before getting started.

Quick start

  1. Yoink the minimal ISO image of NixOS from the official download page.

  2. Verify integrity of the ISO image and flash to boot medium.

  3. Boot into the installer.

  4. Do your partitions and mount your root to /mnt. I recommend first doing sudo su for ease of use. Be careful with those labels though.

  5. Run nixos-generate-config --root /mnt to produce the default configuration.nix and hardware-configuration.nix.

  6. Make sure you've got a working network connection and clone the repo with git clone /mnt/etc/nixos.

  7. In case this fails, git might not be installed. Run nix-env -iA nixos.git to install and repeat step 4.

  8. For a new host enter the cloned repo and duplicate an existing configuration (cd nixos && cp -r hosts/purple hosts/<new-host>) and make adjustments with nano hosts/<new-host>/default.nix.

  9. Get rid of the default configuration with rm /mnt/configuration.nix and override the hardware configuration in the cloned repo for your host with cp /mnt/hardware-configuration.nix /mnt/etc/nixos/hosts/<new-host>/.

    For a different partitioning scheme make sure to change the hardware-configuration with nano hosts/<new-host>/hardware-configuration.nix.

  10. Add nixPkgs channel and install flakes nix-channel --add nixpkgs && nix-channel --update && nix-env -iA nixpkgs.nixFlakes.

  11. Install NixOS with configuration for host "purple" nixos-install --root /mnt --flake /mnt/etc/nixos#purple.

  12. Reboot!


And I say, bin/hey. What's going on?

Usage: hey [global-options] [command] [sub-options]

Available Commands:
  check                  Run 'nix flake check' on your dotfiles
  gc                     Garbage collect & optimize nix store
  generations            Explore, manage, diff across generations
  help [SUBCOMMAND]      Show usage information for this script or a subcommand
  rebuild                Rebuild the current system's flake
  repl                   Open a nix-repl with nixpkgs and dotfiles preloaded
  rollback               Roll back to last generation
  search                 Search nixpkgs for a package
  show                   [ARGS...]
  ssh HOST [COMMAND]     Run a bin/hey command on a remote NixOS system
  swap PATH [PATH...]    Recursively swap nix-store symlinks with copies (or back).
  test                   Quickly rebuild, for quick iteration
  theme THEME_NAME       Quickly swap to another theme module
  update [INPUT...]      Update specific flakes or all of them
  upgrade                Update all flakes and rebuild system

    -d, --dryrun                     Don't change anything; preform dry run
    -D, --debug                      Show trace on nix errors
    -f, --flake URI                  Change target flake to URI
    -h, --help                       Display this help, or help for a specific command
    -i, -A, -q, -e, -p               Forward to nix-env

Some information to get you started configuring the install to your needs

Mimeapps can be set in modules/xdg.nix.

Frequently asked questions