Dotfiles with NixOS, Noctalia, and Doom Emacs
README.md

Dotfiles #

Author: Arik

A NixOS configuration template using Flakes, designed to allow users to customize their NixOS setup, add packages, and configure themes. This setup utilizes Niri as the window manager, along with NixOS flakes and Home Manager for declarative configuration management.

Thumbnail

Repository #

https://tangled.org/arik.tngl.sh/dotfiles

Key Files and Directories #

  • Almost everything you need to inspect is in the nixos folder and justfile
  • flake.nix: The entry point for the Nix Flake. Defines inputs and outputs.
  • configuration.nix: The main NixOS system configuration file.
  • hardware-configuration.nix: Hardware-specific settings, usually auto-generated.
  • home.nix: Home Manager configuration for user-specific settings.
  • modules/: Contains custom modules.
    • hm/: Home Manager modules.
    • system/: System-level NixOS modules.
  • docs/: Documentation files.
  • .gitignore: Git ignore rules.
  • AGENTS.md: Context and instructions for AI agents working on this project.
  • Appendix.org: Personal notes and appendix (not for editing by agents).

Features #

  • Declarative NixOS configuration using flakes.
  • Home Manager integration for user environment management.
  • Niri window manager setup.
  • Customizable themes and packages.
  • Modular structure for easy extension.

Installation #

  1. Clone the repository:

    git clone https://tangled.org/arik.tngl.sh/dotfiles
    cd dotfiles
    
  2. Customize the configuration files as needed:

    • Edit configuration.nix for system-wide settings.
    • Edit home.nix for user-specific configurations.
    • Modify modules in modules/ for additional customizations.
  3. Generate or update hardware-configuration.nix if necessary (usually done during NixOS installation).

  4. Build and switch to the new configuration:

    sudo nixos-rebuild switch --flake .#username
    

    Note: Replace username with your hostname if different.

Usage #

  • To apply changes, run the rebuild command:

    sudo nixos-rebuild switch --flake .#arik
    
  • Use nix flake check to verify that the configuration compiles without errors before rebuilding.

  • For development, follow the Manus workflow as described in AGENTS.md for complex tasks.

Development Guidelines #

  • Use Nushell (nu) for scripting.
  • Follow the planning-with-files workflow for complex tasks: In .planning Create task_plan.md, notes.md, and deliverable files in a manus/task/ subfolder.
  • Prefer editing Home Manager configurations or files in modules/ when modifying settings.
  • Update flake.nix if new inputs are required.
  • Follow Nix language best practices.
  • Comment thoroughly on additions.
  • Log mistakes and corrections in comments.
  • Use log files for debugging instead of terminal output.
  • Comment out lines instead of deleting them, noting the reason.
  • Use nix flake check to ensure compilation.

Migration Guide #

  • caches wont hit until switched once. recommend slimmer switch rebuild with cache dependencies e.g. noctalia or cachyos to be commented out in home.nix or configuration.nix, - also git is not installed by default on new nixos systems
  • also hardware-configuration is system dependent generated in etc/nixos typically

Troubleshooting #

  • If issues arise, refer to troubleshooting.md for logging complex troubleshooting steps.
  • For external drive issues, you may need to adjust permissions, e.g., sudo chown -R arik:users /mnt/arik_s_disk/SteamLibrary/steamapps/compatdata.
  • Dota 2 audio issues can be fixed with launch option -sdlaudiodriver pulse.
  • Right now i have an issue with emacs not compiling successfully

Contributing #

Contributions are welcome. Please follow the development guidelines and use the Manus workflow for significant changes.

License #

All rights reserved to dotfiles creator.