Skip to content

hlissner/dotfiles

Repository files navigation

Made with Doom Emacs NixOS Unstable

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.

Important

Disclaimer: This is not a "community framework" or "NixOS distribution". Please do not use it like one. It is an ongoing and haphazard experiment to feel out NixOS for my own purposes, and is home to all manner of unspeakable, overly-opinionated hackery that make the other 9 circles of hell look like tropical beach resorts.

Until I can bend spoons with my Nix-fu, please divert your general Nix(OS) questions to the NixOS discourse instead of my issue tracker. That said, I'm more than happy to hear input and discuss ideas, but be warned: I struggle to stay on top of Github notifications most of the time.

(screenshots coming soon)


Wayland X11
Shell: zsh + zgenom "
WM: hyprland + waybar lightdm + lightdm-mini-greeter + bspwm + polybar
Editor: Doom Emacs "
Terminal: foot st
Launcher: rofi "
Browser: firefox "

Quick start

  1. Acquire or build a NixOS 24.05+ image:

    # Yoink nixos-unstable from upstream
    $ wget -O nixos.iso https://channels.nixos.org/nixos-unstable/latest-nixos-minimal-x86_64-linux.iso
  2. Write it to a USB drive:

    # Replace /dev/sdX with the correct partition!
    $ cp nixos.iso /dev/sdX
  3. Restart and boot into the installer.

  4. Do your partitions and mount your root to /mnt (for example).

  5. Clone these dotfiles somewhere:

    $ git clone --recursive https://github.com/hlissner/dotfiles
  6. Create a host config in hosts/ (see existing ones for examples).

  7. Run the installer:

    # The options are optional, but these are their default values, if you omit them.
    $ dotfiles/install.zsh \ 
          --root /mnt \
          --flake /mnt/etc/dotfiles \
          --user "$USER" \
          --host "$HOST" \
          --dest /mnt/home/$USER/.config/dotfiles
  8. Then reboot and you're good to go!

Warning

Don't forget to change your root and $USER passwords! They are set to nixos by default.

Management

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

SYNOPSIS:
  hey [-?|-??|-???|-!] [-h|--help] COMMAND [ARGS...]

OPTIONS:
  -!           -- Do a dry run. WARNING: It's up to called scripts to obey!
  -?,-??,-???  -- Enable debug (verbose) mode.
  -h,--help    -- Display the documentation embedded in a target script's
                  header.

COMMANDS:
  - build|b    -- Build nix images or recompile bin/hey
  - exec       -- Dispatch to $DOTFILES_HOME/{,hosts/$HOST,config/$WM}/bin/shim.d $PATH
  - get|set    -- Alias for hey vars {get,set} ...
  - gc         -- Run garbage collection on the user's/system's profile
  - help|h     -- Display documentation for the command
  - hook       -- Trigger scripts associated with an event
  - host       -- Dispatch to $DOTFILES_HOME/hosts/$HOST/bin
  - info       -- Display information about current system (JSON)
  - path       -- Display path to area of my dotfiles
  - profile    -- Manage or analyze a system or user nix profile
  - pull       -- Update flake inputs
  - reload     -- Run reload hooks
  - repl       -- Open a Janet, Nix, or nix-develop REPL
  - swap       -- Swap nix-store symlinks with copies (and back)
  - sync|s     -- Rebuild this flake (using nixos-rebuild)
  - test       -- Run Hey and/or Nix test suites
  - which      -- Print out the script's path (with arguments) w/o executing it
  - wm         -- Dispatch to $DOTFILES_HOME/config/$WM/bin
  - vars       -- Get or set session or persistent state in userspace.
  - @*         -- Dispatch to $DOTFILES_HOME/config/${1#@}/bin
  - .*         -- Tries to be smart. Looks for any executable under host, wm,
                  then $DOTFILES_HOME/bin.

Frequently asked questions