Thanks to visit codestin.com
Credit goes to github.com

Skip to content

kenanpelit/nixosc

Repository files navigation

NixOS Configuration Suite (nixosc)


Kenan's NixOS Configuration Suite

🖼️ Gallery




📋 Project Overview

NixOS Configuration Suite (nixosc) - Snowfall Edition

A comprehensive NixOS configuration built on Snowfall Lib, managing both system (NixOS) and user (Home Manager) layers from a single flake.

  • Architecture: Snowfall Lib (auto module discovery)
  • Desktop: Hyprland + Niri + GNOME (optional) + DankMaterialShell (DMS); Waybar/Hyprpanel disabled by default
  • Greeter: greetd + DMS Greeter (dms-greeter) on supported hosts
  • Launchers: DMS Spotlight + Walker (Elephant) + Rofi; Ulauncher is also configured
  • Theme: Catppuccin (Mocha by default) end-to-end
  • Shell: Zsh + Starship + Tmux + Kitty/Wezterm
  • Secrets: SOPS-Nix (Age)

🗃️ Repository Structure

Snowfall layout (all modules auto-imported via default.nix):

  • flake.nix - Core configuration entry point
  • install.sh - Unified installation & management tool
  • systems - ❄️ Host configurations
    • hay - Laptop/Workstation
    • vhay - VM profile
  • modules - 🍱 Modular configs
    • nixos - System-level (hardware, services, security, networking…)
    • home - User-level (apps, theming, shells, Hyprland, DMS, scripts)
  • homes - Home-Manager profiles per host/user
  • overlays - 🔧 Nixpkgs overlays
  • secrets - 🔐 SOPS-encrypted material
  • wallpapers - Theme assets used by DMS/Hyprland

🧩 Components & Technologies

Core Systems

Component Technology
Base System NixOS 25.11
Framework Snowfall Lib
User Environment Home-Manager
Secrets Management SOPS-nix (Age)

Desktop Environment

Component Implementation
Compositors / Sessions Hyprland (optimized), Niri, GNOME
Shell / Panel DankMaterialShell (DMS)
Greeter greetd + DMS Greeter (dms-greeter)
Launcher DMS Spotlight + Walker + Rofi (+ Ulauncher)
Notifications & Widgets DMS built-ins
Lock / Power DMS lock/powermenu (DMS uses wl-session-lock; Niri uses niri-lock wrapper for consistent UI)
Wallpaper DMS wallpaper engine (Hyprpaper present; Waypaper/Wpaperd removed)
Browsers Brave primary; Chrome profiles optional; Zen/Vivaldi removed

🚀 Installation

Caution

This configuration is tailored for specific hardware. Review hardware-configuration.nix before applying.

1. Clone & Setup

git clone https://github.com/kenanpelit/nixosc ~/.nixosc
cd ~/.nixosc

2. Install / Switch

Use the helper script to build and switch configurations:

# For Physical Machine (hay)
./install.sh install hay

# For Virtual Machine (vhay)
./install.sh install vhay

3. Update

To update flake inputs:

./install.sh update

🪪 Greeter (greetd + DMS Greeter)

This repo can run the login screen using DMS Greeter (dms-greeter) under greetd.

Host example: systems/x86_64-linux/hay/default.nix

my.greeter.dms = {
  enable = true;
  compositor = "hyprland"; # hyprland | niri | sway
  layout = "tr";
  variant = "f";
};

Notes:

  • Logs: /var/log/dms-greeter/dms-greeter.log
  • The module sets a writable greeter HOME (/var/lib/dms-greeter) to avoid cache/shader warnings.

⚙️ Customization Guide

Adding a Package

  • System-wide: Edit modules/nixos/packages/default.nix.
  • User-specific: Edit modules/home/packages/default.nix.

Creating a New Module

Just create a directory! Snowfall Lib automatically imports default.nix files.

  • System module: modules/nixos/my-service/default.nix
  • User module: modules/home/my-app/default.nix

Managing Secrets

Secrets are encrypted with Age and managed by SOPS. To edit secrets:

sops secrets/wireless-secrets.enc.yaml

⌨️ Keybindings (Niri / Hyprland + DMS)

Niri + DMS

  • Mod is the main modifier (typically SUPER in a normal session).
  • Alt + L — DMS lock (via niri-lock)
  • Mod + Space — DMS Spotlight
  • Reload config (no restart): niri msg action load-config-file
  • Full config generator: modules/home/niri/default.nix

Hyprland + DMS

  • $mainMod = SUPER key
  • DMS ships Spotlight/panel shortcuts ($mainMod+Space, powermenu, control-center, etc.).
  • Hyprland core (summary):
    • $mainMod + Enter — Kitty
    • $mainMod + Q — Close window
    • $mainMod + F — Toggle float; $mainMod+Shift+F — Fullscreen
    • $mainMod + h/j/k/l or arrows — Move focus; Shift moves window; Ctrl resizes
    • $mainMod + 1-9 — Workspace; Shift+1-9 — move window; Ctrl+1-9 — monitor-aware move
    • $mainMod + Tab — DMS Hypr overview
  • Full list: modules/home/hyprland/config.nix

🛠 Troubleshooting

DMS warnings about Niri config writes

DMS may log lines like:

  • NiriService: Failed to write layout config
  • NiriService: Failed to write alttab config

This repo intentionally manages ~/.config/niri/dms/*.kdl via Home Manager (read-only symlinks), so DMS' auto-generator can't overwrite them.

Stasis (idle manager) config is writable by design

This repo ships a Home-Manager module for Stasis.

Enable it in your HM profile:

my.user.stasis.enable = true;

Notes:

  • Config path: ~/.config/stasis/stasis.rune
  • The file is created via home.activation (not xdg.configFile) so it stays writable.
  • Convenience wrapper: stasisctl ... (always uses the configured stasis.rune path)

Useful commands:

systemctl --user status stasis
stasisctl info --json
stasisctl reload
stasisctl profile work    # or: none / presentation
stasisctl dump 80

📄 License

This project is licensed under the MIT License - see the LICENSE file for details.