My NixOS configuration using flakes with Hyprland, Quickshell, Home Manager, and modular structure.
This repository contains a complete NixOS configuration featuring:
- Hyprland - Modern Wayland compositor
- Quickshell - Modern Qt6/QML-based desktop shell
- Home Manager - Declarative user environment management
- Stylix - System-wide theming with automatic Quickshell integration
- Modular structure - Clean separation of concerns
- NixOS installed with flakes enabled
- Git for cloning this repository
- Ensure
/usr/share/wallpaper/exists and contains all wallpapers you want to use for theming
- Clone this repository:
git clone https://github.com/FinnPL/nixos-config /etc/nixos
cd /etc/nixos- Deploy the configuration:
chmod +x deploy.sh
./deploy.sh- To update flake inputs before deployment:
./deploy.sh -upTo change the active theme, edit flake.nix and set activeTheme to your desired theme (e.g., themes.mytheme).
The configuration is built using Nix flakes with the following inputs:
- nixpkgs - Latest unstable channel
- home-manager - User environment management
- firefox-addons - Firefox extensions via NUR
- stylix - System-wide theming framework
- hyprland - Wayland compositor and plugins
├── flake.nix # Main flake configuration
├── flake.lock # Locked input versions
├── deploy.sh # Deployment script
├── hosts/ # Host-specific configurations
│ └── centaur/
│ ├── configuration.nix # System configuration
│ ├── hardware-configuration.nix # Hardware settings
│ └── home.nix # User configuration
├── modules/ # Modular configurations
│ ├── home-manager/ # User-level modules
│ ├── hyprland/ # Hyprland-specific modules
│ ├── nixos/ # System-level modules
│ └── quickshell/ # Quickshell desktop shell
└── none-nix/ # Non-Nix configuration files
Located in modules/home-manager/:
- basics.nix - Essential packages and settings
- cli-tools.nix - Command-line utilities
- discord.nix - Discord configuration
- firefox.nix - Firefox with extensions
- jetbrains.nix - JetBrains IDE suite
- kitty.nix - Terminal emulator configuration
- python-packages.nix - Python development environment
- thunderbird.nix - Email client
- vscode.nix - Visual Studio Code setup
- zsh.nix - Zsh shell configuration
Located in modules/hyprland/:
- default.nix - Main Hyprland configuration
- hyprland-config.nix - Window manager settings
- waybar.nix - Status bar configuration
- rofi.nix - Application launcher
- mako.nix - Notification daemon
- hyprpaper.nix - Wallpaper management
- cliphist.nix - Clipboard history
Located in modules/quickshell/:
This is a complete Qt6/QML desktop shell based on illogical-impulse, featuring:
- shell-config.nix - Main Quickshell configuration and Nix integration
- generate-colors.py - Automatic Material Design color generation from Stylix theme
- config/ - QML shell components including:
- Bar - Status bar with system info, weather, workspaces
- Overview - Window overview and app launcher
- Sidebar - Notifications, calendar, quick toggles
- Lock screen - Session lock with customizable clock widgets
- On-screen display - Volume, brightness indicators
- Notification popups - Desktop notifications
- Session screen - Power/logout menu
- Stylix Integration - Colors automatically generated from your theme
- Declarative Config - All settings managed through Nix
- Services - Weather, battery, audio, Bluetooth, network status, and more
- Search - App launcher with math, web search, and file search capabilities
Located in modules/nixos/:
- auto.nix - Automatic updates and cleanup
- stylix-config.nix - System-wide theming
The configuration includes automatic maintenance via modules/nixos/auto.nix:
- System updates: Weekly automatic updates
- Garbage collection: Weekly cleanup of packages older than 10 days
- Store optimization: Automatic Nix store optimization
# Update flake inputs
nix flake update
# Garbage collect old generations
sudo nix-collect-garbage -d
# Optimize Nix store
sudo nix-store --optimizeTo add a new theme:
- Add your color scheme YAML file to
modules/nixos/themes/(e.g.,mytheme.yaml). - Add your wallpaper image to
/usr/share/wallpaper/(e.g.,mytheme.jpg). - Edit
modules/nixos/themes/defaults.nixto include your new theme:mytheme = { colorScheme = ./mytheme.yaml; wallpaper = "mytheme.jpg"; };
To change the active theme, edit flake.nix and set activeTheme to your desired theme (e.g., themes.mytheme).
-
Create module file in appropriate directory:
- System modules:
modules/nixos/ - User modules:
modules/home-manager/ - Hyprland modules:
modules/hyprland/
- System modules:
-
Import in relevant configuration:
- System: Add to
hosts/centaur/configuration.nix - User: Add to
hosts/centaur/home.nix
- System: Add to
To add a new host:
- Create directory:
hosts/<hostname>/ - Add required files:
configuration.nixhardware-configuration.nixhome.nix
- Update
flake.nixto include new host