Compare commits
9
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
24216aca9d | ||
|
|
fd79c661a1 | ||
|
|
8ac7fd4862 | ||
|
|
3fb55bb091 | ||
|
|
269c49b2d5 | ||
|
|
b80d6b9b1f | ||
|
|
ee97c00b65 | ||
|
|
db47fa9663 | ||
|
|
7b094256a4 |
No files matched your search
@@ -1,67 +0,0 @@
|
||||
# Makefile to safely clean up NixOS profiles, keeping only the last 3 generations.
|
||||
|
||||
.PHONY: help dry-run clean-system clean-user clean-home-manager clean-all
|
||||
|
||||
# Default target displays the help menu
|
||||
help:
|
||||
@echo "NixOS Profile Cleanup Utility"
|
||||
@echo "============================="
|
||||
@echo "Available targets:"
|
||||
@echo " make dry-run - Safe preview of what will be deleted"
|
||||
@echo " make clean-system - Clean system generations and update bootloader (requires sudo)"
|
||||
@echo " make clean-user - Clean current user's profile generations"
|
||||
@echo " make clean-home-manager - Clean Home Manager generations (if applicable)"
|
||||
@echo " make clean-all - Clean everything (System, User, and Home Manager)"
|
||||
|
||||
# Dry run to preview changes without deleting anything
|
||||
dry-run:
|
||||
@echo "=== [DRY RUN] System Profile ==="
|
||||
sudo nix-env --profile /nix/var/nix/profiles/system --delete-generations +3 --dry-run
|
||||
@echo "\n=== [DRY RUN] User Profile ==="
|
||||
nix-env --delete-generations +3 --dry-run
|
||||
@echo "\n=== [DRY RUN] Home Manager Profile ==="
|
||||
@if [ -d "$$HOME/.local/state/nix/profiles/home-manager" ]; then \
|
||||
nix-env --profile "$$HOME/.local/state/nix/profiles/home-manager" --delete-generations +3 --dry-run; \
|
||||
elif [ -d "$$HOME/.nix-profile" ]; then \
|
||||
echo "No Home Manager directory found, but user profile exists."; \
|
||||
else \
|
||||
echo "No Home Manager profile detected."; \
|
||||
fi
|
||||
|
||||
# Clean system generations (requires sudo)
|
||||
clean-system:
|
||||
@echo "--- Cleaning System Profile (SUDO) ---"
|
||||
sudo nix-env --profile /nix/var/nix/profiles/system --delete-generations +3
|
||||
sudo nix-collect-garbage
|
||||
@echo "--- Updating Bootloader Menu ---"
|
||||
sudo nixos-rebuild boot --flake
|
||||
|
||||
# Clean user generations (no sudo)
|
||||
clean-user:
|
||||
@echo "--- Cleaning User Profile ---"
|
||||
nix-env --delete-generations +3
|
||||
nix-collect-garbage
|
||||
|
||||
# Clean Home Manager generations (no sudo)
|
||||
clean-home-manager:
|
||||
@echo "--- Cleaning Home Manager Profile ---"
|
||||
@if [ -d "$$HOME/.local/state/nix/profiles/home-manager" ]; then \
|
||||
nix-env --profile "$$HOME/.local/state/nix/profiles/home-manager" --delete-generations +3; \
|
||||
nix-collect-garbage; \
|
||||
else \
|
||||
echo "No Home Manager profile found. Skipping."; \
|
||||
fi
|
||||
|
||||
# Clean everything in one go
|
||||
clean-all: clean-system clean-user clean-home-manager
|
||||
@echo "All cleanups successfully completed!"
|
||||
|
||||
# Rebuild
|
||||
rebuild:
|
||||
@echo "--- Rebuilding System ---"
|
||||
sudo nixos-rebuild switch --flake
|
||||
|
||||
# Update flake
|
||||
update:
|
||||
@echo "--- Updating Flake ---"
|
||||
sudo nix flake update
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 978 KiB |
-46
@@ -1,46 +0,0 @@
|
||||
{ pkgs, lib, config, inputs, ... }:
|
||||
|
||||
{
|
||||
# https://devenv.sh/basics/
|
||||
env.GREET = "devenv";
|
||||
|
||||
# https://devenv.sh/packages/
|
||||
packages = [ pkgs.git ];
|
||||
|
||||
# https://devenv.sh/languages/
|
||||
# languages.rust.enable = true;
|
||||
|
||||
# https://devenv.sh/processes/
|
||||
# processes.dev.exec = "${lib.getExe pkgs.watchexec} -n -- ls -la";
|
||||
|
||||
# https://devenv.sh/services/
|
||||
# services.postgres.enable = true;
|
||||
|
||||
# https://devenv.sh/scripts/
|
||||
scripts.hello.exec = ''
|
||||
echo hello from $GREET
|
||||
'';
|
||||
|
||||
# https://devenv.sh/basics/
|
||||
enterShell = ''
|
||||
hello # Run scripts directly
|
||||
git --version # Use packages
|
||||
'';
|
||||
|
||||
# https://devenv.sh/tasks/
|
||||
# tasks = {
|
||||
# "myproj:setup".exec = "mytool build";
|
||||
# "devenv:enterShell".after = [ "myproj:setup" ];
|
||||
# };
|
||||
|
||||
# https://devenv.sh/tests/
|
||||
enterTest = ''
|
||||
echo "Running tests"
|
||||
git --version | grep --color=auto "${pkgs.git.version}"
|
||||
'';
|
||||
|
||||
# https://devenv.sh/git-hooks/
|
||||
# git-hooks.hooks.shellcheck.enable = true;
|
||||
|
||||
# See full reference at https://devenv.sh/reference/options/
|
||||
}
|
||||
-18
@@ -1,18 +0,0 @@
|
||||
# yaml-language-server: $schema=https://devenv.sh/devenv.schema.json
|
||||
inputs:
|
||||
nixpkgs:
|
||||
url: github:cachix/devenv-nixpkgs/rolling
|
||||
|
||||
# If you're using non-OSS software, you can set allow_unfree to true.
|
||||
# allow_unfree: true
|
||||
|
||||
# If you're not willing to allow unsupported packages:
|
||||
# allow_unsupported_system: false
|
||||
|
||||
# If you're willing to use a package that's vulnerable
|
||||
# permitted_insecure_packages:
|
||||
# - "openssl-1.1.1w"
|
||||
|
||||
# If you have more than one devenv you can merge them
|
||||
#imports:
|
||||
# - ./backend
|
||||
Generated
+53
-10
@@ -7,11 +7,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1784789275,
|
||||
"narHash": "sha256-cgRTWuG+u1tBPhm01JrId2k0Bni09phVJ1Q0BZlRd7M=",
|
||||
"lastModified": 1792668857,
|
||||
"narHash": "sha256-chUrnAqBhBLvXBUsLFxFYBIl8c0GWp06wdjmAMS8l+U=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "3b0e6bbd65869af1beadf5963a99befc179d209f",
|
||||
"rev": "cb7de2c7e589afe7531d4832c71ad4df144624ea",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -22,11 +22,11 @@
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1784497964,
|
||||
"narHash": "sha256-WhdsTtaih3DgTPP/PX023b36UNQyMzEoi6GkPyGx0y4=",
|
||||
"rev": "241313f4e8e508cb9b13278c2b0fa25b9ca27163",
|
||||
"lastModified": 1792502884,
|
||||
"narHash": "sha256-ij8QUxzTOHovLrNOxVRx+RAhGQFOMsJbji0veiatH5k=",
|
||||
"rev": "02c087f3fe673c9e317f206a627cb6b910336dbe",
|
||||
"type": "tarball",
|
||||
"url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1037713.241313f4e8e5/nixexprs.tar.xz"
|
||||
"url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1097682.02c087f3fe67/nixexprs.tar.zst"
|
||||
},
|
||||
"original": {
|
||||
"id": "nixpkgs",
|
||||
@@ -38,9 +38,52 @@
|
||||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"xwayland-satellite": "xwayland-satellite",
|
||||
"zen-browser": "zen-browser"
|
||||
}
|
||||
},
|
||||
"rust-overlay": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"xwayland-satellite",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1769222645,
|
||||
"narHash": "sha256-gu6oZ86zLudBZMq8LL1qdtYt/S69GV5keQVXdvBrVSU=",
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"rev": "22da29e7f3d8cff75009cbbcf992c7cb66920cfd",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"xwayland-satellite": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"rust-overlay": "rust-overlay"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1792070459,
|
||||
"narHash": "sha256-qGSyMXPHiXWp9/nE5Zs1DJN5NmZFvoxaBS5Y9i7p0Pc=",
|
||||
"owner": "Supreeeme",
|
||||
"repo": "xwayland-satellite",
|
||||
"rev": "97a89cec53eb4f8788386a574450dd94c0538754",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Supreeeme",
|
||||
"repo": "xwayland-satellite",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"zen-browser": {
|
||||
"inputs": {
|
||||
"home-manager": [
|
||||
@@ -51,11 +94,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1784822396,
|
||||
"narHash": "sha256-gW59E7cwPetoOAcygLtHQX7a3C8VdWz6T0GazldcxU0=",
|
||||
"lastModified": 1792595242,
|
||||
"narHash": "sha256-kH/E0uJDslOgYcnmU+c0cm6HrUjsEtvZQKZtuQ1+uvo=",
|
||||
"owner": "0xc000022070",
|
||||
"repo": "zen-browser-flake",
|
||||
"rev": "a68b1580a237cae4c9f86e04ac972726e3f87fdb",
|
||||
"rev": "f19490ac889eabb05bdb7e8dcb85225ee75bd87b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
||||
@@ -14,6 +14,10 @@
|
||||
home-manager.follows = "home-manager";
|
||||
};
|
||||
};
|
||||
xwayland-satellite = {
|
||||
url = "github:Supreeeme/xwayland-satellite";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs =
|
||||
@@ -23,8 +27,11 @@
|
||||
...
|
||||
}:
|
||||
{
|
||||
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt-tree;
|
||||
|
||||
nixosConfigurations.prouk = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [
|
||||
./nixos
|
||||
home-manager.nixosModules.home-manager
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
[window]
|
||||
|
||||
padding = {
|
||||
x = 5,
|
||||
y = 5
|
||||
}
|
||||
|
||||
decorations = "None"
|
||||
|
||||
opacity = 0.8
|
||||
@@ -1,8 +0,0 @@
|
||||
{ ... }:
|
||||
{
|
||||
xdg.configFile."niri" = {
|
||||
force = true;
|
||||
recursive = true;
|
||||
source = ./niri;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
[main]
|
||||
use-bold=yes
|
||||
dpi-aware=no
|
||||
fields=name,generic,comment,categories,filename,keywords,exec
|
||||
terminal=alacritty
|
||||
prompt="What ? "
|
||||
placeholder="Search and launch"
|
||||
icon-theme=Papirus
|
||||
icons-enabled=yes
|
||||
show-actions=no
|
||||
anchor=center
|
||||
x-margin=10
|
||||
y-margin=10
|
||||
lines=10
|
||||
width=60
|
||||
horizontal-pad=20
|
||||
vertical-pad=20
|
||||
inner-pad=5
|
||||
line-height=27
|
||||
letter-spacing=0
|
||||
image-size-ratio=0.4
|
||||
layer=top
|
||||
exit-on-keyboard-focus-loss = yes
|
||||
|
||||
[colors]
|
||||
background=140c1dfa
|
||||
prompt=dcd7baff
|
||||
input=dcd7baff
|
||||
text=938aa9ff
|
||||
match=1c0c1dff
|
||||
selection=1c0c1dff
|
||||
selection-text=161736
|
||||
|
||||
[border]
|
||||
width=0
|
||||
radius=7
|
||||
@@ -0,0 +1,19 @@
|
||||
theme = "kanagawa-dragon-transparent"
|
||||
|
||||
[editor]
|
||||
line-number = "relative"
|
||||
cursorline = true
|
||||
color-modes = true
|
||||
bufferline = "multiple"
|
||||
true-color = true
|
||||
|
||||
[editor.cursor-shape]
|
||||
insert = "bar"
|
||||
normal = "block"
|
||||
select = "underline"
|
||||
|
||||
[editor.indent-guides]
|
||||
render = true
|
||||
|
||||
[editor.lsp]
|
||||
display-inlay-hints = true
|
||||
@@ -0,0 +1,3 @@
|
||||
inherits = "kanagawa-dragon"
|
||||
|
||||
"ui.background" = { fg = "dragonWhite" }
|
||||
@@ -1,2 +1,10 @@
|
||||
animations {
|
||||
window-open {
|
||||
duration-ms 200
|
||||
curve "ease-out-expo"
|
||||
}
|
||||
window-close {
|
||||
duration-ms 150
|
||||
curve "ease-out-quad"
|
||||
}
|
||||
}
|
||||
@@ -19,3 +19,10 @@ cursor {
|
||||
prefer-no-csd
|
||||
|
||||
screenshot-path "~/Pictures/Screenshots/Screenshot from %Y-%m-%d %H-%M-%S.png"
|
||||
|
||||
blur {
|
||||
passes 3
|
||||
offset 3.0
|
||||
noise 0.02
|
||||
saturation 1.75
|
||||
}
|
||||
@@ -44,12 +44,12 @@ environment {
|
||||
// Clutter: Force Wayland backend.
|
||||
CLUTTER_BACKEND "wayland"
|
||||
|
||||
// Firefox: Force native Wayland rendering (massively improves scrolling smoothness).
|
||||
MOZ_ENABLE_WAYLAND "1"
|
||||
|
||||
// Electron/Chromium: Automatically flags apps (VS Code, Discord, Obsidian) to use Wayland.
|
||||
ELECTRON_OZONE_PLATFORM_HINT "auto"
|
||||
|
||||
// GTK: Route file dialogs through the XDG portal (yazi file picker).
|
||||
GDK_DEBUG "portals"
|
||||
|
||||
// =========================================================================
|
||||
// 5. DESKTOP SESSION IDENTIFICATION
|
||||
// =========================================================================
|
||||
@@ -57,4 +57,11 @@ environment {
|
||||
XDG_SESSION_TYPE "wayland"
|
||||
XDG_CURRENT_DESKTOP "niri"
|
||||
XDG_SESSION_DESKTOP "niri"
|
||||
|
||||
// =========================================================================
|
||||
// 6. STEAM / PROTON
|
||||
// =========================================================================
|
||||
// Stuff for gaming
|
||||
PROTON_ADD_CONFIG "wayland,dlss"
|
||||
DXVK_CONFIG "dxvk.enableNvRawAccessChains=False"
|
||||
}
|
||||
@@ -16,6 +16,7 @@ binds {
|
||||
Mod+Down { focus-workspace-down; }
|
||||
|
||||
Mod+R { switch-preset-column-width; }
|
||||
Mod+Shift+R { switch-preset-column-width-back; }
|
||||
|
||||
Mod+Ctrl+R { reset-window-height; }
|
||||
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
layout {
|
||||
background-color "transparent"
|
||||
gaps 16
|
||||
gaps 3
|
||||
|
||||
center-focused-column "never"
|
||||
|
||||
preset-column-widths {
|
||||
proportion 0.33333
|
||||
proportion 0.5
|
||||
proportion 0.66667
|
||||
proportion 1.0
|
||||
}
|
||||
|
||||
default-column-width { proportion 0.5; }
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
spawn-at-startup "awww-daemon"
|
||||
spawn-at-startup "awww img ~/Pictures/Wallpapers/Wallpaper.png --resize crop --crop-gravity center"
|
||||
spawn-at-startup "awww img ~/Pictures/Wallpapers/wallpaper.png --resize crop --crop-gravity center"
|
||||
@@ -3,7 +3,18 @@ window-rule {
|
||||
open-floating true
|
||||
}
|
||||
|
||||
window-rule {
|
||||
match title="^termfilechooser$"
|
||||
open-floating true
|
||||
default-column-width { proportion 0.6; }
|
||||
default-window-height { proportion 0.6; }
|
||||
}
|
||||
|
||||
window-rule {
|
||||
geometry-corner-radius 12
|
||||
clip-to-geometry true
|
||||
|
||||
background-effect {
|
||||
blur true
|
||||
}
|
||||
}
|
||||
+9
-30
@@ -1,37 +1,16 @@
|
||||
{
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./user.nix
|
||||
./programs.nix
|
||||
./code.nix
|
||||
./config
|
||||
./look.nix
|
||||
./shell.nix
|
||||
./dotfiles.nix
|
||||
./portal.nix
|
||||
./packages
|
||||
];
|
||||
|
||||
programs.git.enable = true;
|
||||
programs.bash.enable = true;
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
enableBashIntegration = true;
|
||||
home = {
|
||||
username = "prouk";
|
||||
homeDirectory = "/home/prouk";
|
||||
stateVersion = "26.05";
|
||||
};
|
||||
home.packages = with pkgs; [
|
||||
xwayland-satellite
|
||||
github-copilot-cli
|
||||
vesktop
|
||||
pavucontrol
|
||||
wev
|
||||
lutris
|
||||
fuzzel
|
||||
gparted
|
||||
yazi
|
||||
btop
|
||||
awww
|
||||
wootility
|
||||
wooting-udev-rules
|
||||
];
|
||||
home.stateVersion = "26.05";
|
||||
}
|
||||
@@ -0,0 +1,31 @@
|
||||
{ ... }:
|
||||
{
|
||||
# Desktop
|
||||
xdg.configFile."niri" = {
|
||||
force = true;
|
||||
recursive = true;
|
||||
source = ./config/niri;
|
||||
};
|
||||
xdg.configFile."fuzzel" = {
|
||||
force = true;
|
||||
recursive = true;
|
||||
source = ./config/fuzzel;
|
||||
};
|
||||
# Shared with SDDM (nixos/desktop/sddm.nix); niri loads it from this path.
|
||||
home.file."Pictures/Wallpapers/wallpaper.png" = {
|
||||
force = true;
|
||||
source = ../assets/wallpaper.png;
|
||||
};
|
||||
|
||||
# Terminal
|
||||
xdg.configFile."alacritty" = {
|
||||
force = true;
|
||||
recursive = true;
|
||||
source = ./config/alacritty;
|
||||
};
|
||||
xdg.configFile."helix" = {
|
||||
force = true;
|
||||
recursive = true;
|
||||
source = ./config/helix;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
helvum
|
||||
pavucontrol
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./desktop.nix
|
||||
./system.nix
|
||||
./audio.nix
|
||||
./hardware.nix
|
||||
./development.nix
|
||||
./web.nix
|
||||
./media.nix
|
||||
./gaming.nix
|
||||
];
|
||||
}
|
||||
@@ -1,9 +1,15 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
gtk = {
|
||||
enable = true;
|
||||
};
|
||||
home.packages = with pkgs; [
|
||||
alacritty
|
||||
awww
|
||||
fuzzel
|
||||
wev
|
||||
wl-clip-persist
|
||||
];
|
||||
|
||||
# Theming
|
||||
gtk.enable = true;
|
||||
home.pointerCursor = {
|
||||
enable = true;
|
||||
gtk.enable = true;
|
||||
@@ -13,4 +19,10 @@
|
||||
name = "Colloid-dark-cursors";
|
||||
size = 24;
|
||||
};
|
||||
|
||||
# Removable drives
|
||||
services.udiskie = {
|
||||
enable = true;
|
||||
automount = true;
|
||||
};
|
||||
}
|
||||
@@ -1,12 +1,19 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs.zed-editor = {
|
||||
enable = true;
|
||||
defaultEditor = true;
|
||||
};
|
||||
home.packages = with pkgs; [
|
||||
devenv
|
||||
github-copilot-app
|
||||
github-copilot-cli
|
||||
helix
|
||||
jujutsu
|
||||
just
|
||||
nil
|
||||
nixd
|
||||
scrcpy
|
||||
];
|
||||
|
||||
programs.zed-editor = {
|
||||
enable = true;
|
||||
defaultEditor = false;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
# Launchers
|
||||
gamma-launcher
|
||||
lutris
|
||||
|
||||
# Wine / Proton
|
||||
protontricks
|
||||
protonup-qt
|
||||
steamtinkerlaunch
|
||||
winetricks
|
||||
|
||||
# Overlays
|
||||
mangohud
|
||||
|
||||
# Path of Exile
|
||||
awakened-poe-trade
|
||||
rusty-path-of-building
|
||||
];
|
||||
|
||||
xdg.desktopEntries."awakened-poe-trade" = {
|
||||
name = "Awakened PoE Trade";
|
||||
exec = "${pkgs.awakened-poe-trade}/bin/awakened-poe-trade --no-overlay --listen=0.0.0.0:33333 %U";
|
||||
terminal = false;
|
||||
type = "Application";
|
||||
icon = "awakened-poe-trade";
|
||||
categories = [
|
||||
"Game"
|
||||
"Utility"
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
wootility
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
sone
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
btop
|
||||
gparted
|
||||
yazi
|
||||
unzip
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,43 @@
|
||||
{ pkgs, inputs, ... }:
|
||||
let
|
||||
# Track latest upstream Equicord release (nixpkgs lags behind).
|
||||
equicord = pkgs.equicord.overrideAttrs (
|
||||
finalAttrs: prev: {
|
||||
version = "2026-10-01";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "Equicord";
|
||||
repo = "Equicord";
|
||||
tag = finalAttrs.version;
|
||||
hash = "sha256-hk2/djNmbwIBwVAJ1bj3ayurj85EPfMUgmAr1SpYlvw=";
|
||||
};
|
||||
pnpmDeps = prev.pnpmDeps.overrideAttrs {
|
||||
inherit (finalAttrs) src;
|
||||
outputHash = "sha256-rx8z6PAlAPaZbkmg+3Vvq8OXR/yy5ZP0PmAk97ZDOSQ=";
|
||||
};
|
||||
}
|
||||
);
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.zen-browser.homeModules.twilight
|
||||
];
|
||||
|
||||
home.packages = with pkgs; [
|
||||
(discord.override {
|
||||
withEquicord = true;
|
||||
withOpenASAR = true;
|
||||
inherit equicord;
|
||||
})
|
||||
chromium
|
||||
];
|
||||
|
||||
programs.zen-browser = {
|
||||
enable = true;
|
||||
setAsDefaultBrowser = true;
|
||||
profiles.default = {
|
||||
sine.enable = true;
|
||||
# Use the XDG portal (yazi, see home/portal.nix) for file dialogs.
|
||||
settings."widget.use-xdg-desktop-portal.file-picker" = 1;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,53 @@
|
||||
{ pkgs, config, ... }:
|
||||
let
|
||||
termfilechooser = pkgs.xdg-desktop-portal-termfilechooser;
|
||||
in
|
||||
{
|
||||
# Use yazi (in alacritty) as the file picker for every app that goes through
|
||||
# the XDG FileChooser portal.
|
||||
#
|
||||
# Portal/D-Bus files are found through XDG_DATA_DIRS (user profile), so we
|
||||
# deliberately don't enable HM's `xdg.portal`: it would point
|
||||
# NIX_XDG_DESKTOP_PORTAL_DIR at the user profile only and hide the
|
||||
# system-wide gnome/gtk portals that niri relies on.
|
||||
home.packages = [ termfilechooser ];
|
||||
|
||||
# The D-Bus activation file references this unit by name, and HM doesn't
|
||||
# link `share/systemd/user` from packages.
|
||||
systemd.user.services.xdg-desktop-portal-termfilechooser = {
|
||||
Unit = {
|
||||
Description = "Portal service (terminal file chooser implementation)";
|
||||
PartOf = [ "graphical-session.target" ];
|
||||
After = [ "graphical-session.target" ];
|
||||
};
|
||||
Service = {
|
||||
Type = "dbus";
|
||||
BusName = "org.freedesktop.impl.portal.desktop.termfilechooser";
|
||||
ExecStart = "${termfilechooser}/libexec/xdg-desktop-portal-termfilechooser";
|
||||
Environment = [ "PATH=${config.home.profileDirectory}/bin:/run/current-system/sw/bin" ];
|
||||
Restart = "on-failure";
|
||||
Slice = "session.slice";
|
||||
};
|
||||
};
|
||||
|
||||
xdg.configFile = {
|
||||
# Overrides niri's shipped niri-portals.conf, so its entries are repeated here.
|
||||
"xdg-desktop-portal/niri-portals.conf".text = ''
|
||||
[preferred]
|
||||
default=gnome;gtk;
|
||||
org.freedesktop.impl.portal.Access=gtk;
|
||||
org.freedesktop.impl.portal.Notification=gtk;
|
||||
org.freedesktop.impl.portal.Secret=gnome-keyring;
|
||||
org.freedesktop.impl.portal.FileChooser=termfilechooser;
|
||||
'';
|
||||
|
||||
"xdg-desktop-portal-termfilechooser/config".text = ''
|
||||
[filechooser]
|
||||
cmd=${termfilechooser}/share/xdg-desktop-portal-termfilechooser/yazi-wrapper.sh
|
||||
default_dir=$HOME
|
||||
env=TERMCMD=alacritty --title termfilechooser -e
|
||||
open_mode=suggested
|
||||
save_mode=suggested
|
||||
'';
|
||||
};
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
imports = [
|
||||
inputs.zen-browser.homeModules.twilight
|
||||
];
|
||||
|
||||
programs.zen-browser = {
|
||||
enable = true;
|
||||
setAsDefaultBrowser = true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
{ ... }:
|
||||
{
|
||||
programs.fish = {
|
||||
enable = true;
|
||||
# nixpkgs' devenv only ships fish completions, not the auto-loaded hook.
|
||||
interactiveShellInit = ''
|
||||
devenv hook fish | source
|
||||
'';
|
||||
};
|
||||
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
bashrcExtra = "eval \"$(devenv hook bash)\"\n";
|
||||
};
|
||||
|
||||
programs.git.enable = true;
|
||||
}
|
||||
@@ -1,5 +0,0 @@
|
||||
{ ... }:
|
||||
{
|
||||
home.username = "prouk";
|
||||
home.homeDirectory = "/home/prouk";
|
||||
}
|
||||
@@ -0,0 +1,77 @@
|
||||
# Justfile to safely clean up NixOS profiles, keeping only the last 3 generations.
|
||||
# Uses nh (https://github.com/nix-community/nh) when available, falling back to plain nix commands.
|
||||
|
||||
host := "prouk"
|
||||
keep := "3"
|
||||
nh := `command -v nh || true`
|
||||
hm_profile := env("HOME") / ".local/state/nix/profiles/home-manager"
|
||||
|
||||
# Default recipe displays the help menu.
|
||||
help:
|
||||
@echo "NixOS Profile Cleanup Utility"
|
||||
@echo "============================="
|
||||
@echo "nh: {{ if nh != "" { "found (" + nh + ")" } else { "not found, using plain nix commands" } }}"
|
||||
@echo "Available recipes:"
|
||||
@echo " just dry-run - Safe preview of what will be deleted"
|
||||
@echo " just clean-all - Clean System, User and Home Manager generations (requires sudo)"
|
||||
@echo " just build - Rebuild and switch the system"
|
||||
@echo " just update - Update flake inputs"
|
||||
|
||||
# Dry run to preview changes without deleting anything.
|
||||
dry-run:
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
if [ -n "{{ nh }}" ]; then
|
||||
echo "=== [DRY RUN] All profiles (nh) ==="
|
||||
nh clean all --keep {{ keep }} --dry
|
||||
exit 0
|
||||
fi
|
||||
echo "=== [DRY RUN] System Profile ==="
|
||||
sudo nix-env --profile /nix/var/nix/profiles/system --delete-generations +{{ keep }} --dry-run
|
||||
echo -e "\n=== [DRY RUN] User Profile ==="
|
||||
nix-env --delete-generations +{{ keep }} --dry-run
|
||||
echo -e "\n=== [DRY RUN] Home Manager Profile ==="
|
||||
if [ -e "{{ hm_profile }}" ]; then
|
||||
nix-env --profile "{{ hm_profile }}" --delete-generations +{{ keep }} --dry-run
|
||||
elif [ -d "$HOME/.nix-profile" ]; then
|
||||
echo "No Home Manager directory found, but user profile exists."
|
||||
else
|
||||
echo "No Home Manager profile detected."
|
||||
fi
|
||||
|
||||
# Clean system, user and Home Manager generations, then update the bootloader (requires sudo).
|
||||
clean-all:
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
if [ -n "{{ nh }}" ]; then
|
||||
echo "--- Cleaning All Profiles (nh) ---"
|
||||
nh clean all --keep {{ keep }}
|
||||
echo "--- Updating Bootloader Menu ---"
|
||||
nh os boot . --hostname {{ host }}
|
||||
else
|
||||
echo "--- Cleaning System Profile (SUDO) ---"
|
||||
sudo nix-env --profile /nix/var/nix/profiles/system --delete-generations +{{ keep }}
|
||||
echo "--- Cleaning User Profile ---"
|
||||
nix-env --delete-generations +{{ keep }}
|
||||
echo "--- Cleaning Home Manager Profile ---"
|
||||
if [ -e "{{ hm_profile }}" ]; then
|
||||
nix-env --profile "{{ hm_profile }}" --delete-generations +{{ keep }}
|
||||
else
|
||||
echo "No Home Manager profile found. Skipping."
|
||||
fi
|
||||
sudo nix-collect-garbage
|
||||
nix-collect-garbage
|
||||
echo "--- Updating Bootloader Menu ---"
|
||||
sudo nixos-rebuild boot --flake .#{{ host }}
|
||||
fi
|
||||
echo "All cleanups successfully completed!"
|
||||
|
||||
# Build.
|
||||
build:
|
||||
@echo "--- Rebuilding System ---"
|
||||
{{ if nh != "" { "nh os switch . --hostname " + host } else { "sudo nixos-rebuild switch --flake .#" + host } }}
|
||||
|
||||
# Update flake.
|
||||
update:
|
||||
@echo "--- Updating Flake ---"
|
||||
nix flake update
|
||||
+22
-51
@@ -1,64 +1,35 @@
|
||||
{ pkgs, ... }:
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./graphics
|
||||
./audio.nix
|
||||
./fonts/fonts.nix
|
||||
./dm/sddm.nix
|
||||
./wm/niri.nix
|
||||
./inputs/wooting.nix
|
||||
./inputs/wooting.nix
|
||||
./network/bluetooth.nix
|
||||
./steam/steam.nix
|
||||
];
|
||||
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
# System
|
||||
./system/boot.nix
|
||||
./system/nix.nix
|
||||
./system/networking.nix
|
||||
./system/locale.nix
|
||||
./system/users.nix
|
||||
|
||||
networking.hostName = "prouk";
|
||||
networking.networkmanager.enable = true;
|
||||
# Hardware
|
||||
./hardware/graphics.nix
|
||||
./hardware/nvidia.nix
|
||||
./hardware/audio.nix
|
||||
./hardware/bluetooth.nix
|
||||
./hardware/storage.nix
|
||||
./hardware/wooting.nix
|
||||
|
||||
time.timeZone = "Europe/Paris";
|
||||
# Desktop
|
||||
./desktop/fonts.nix
|
||||
./desktop/sddm.nix
|
||||
./desktop/niri.nix
|
||||
|
||||
users.users.prouk = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" ];
|
||||
};
|
||||
|
||||
programs.firefox.enable = true;
|
||||
programs.nix-ld.enable = true;
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.config.permittedInsecurePackages = [
|
||||
"electron-40.10.5"
|
||||
];
|
||||
|
||||
nix.settings.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
# Programs
|
||||
./programs/gaming.nix
|
||||
./programs/obs.nix
|
||||
./programs/nh.nix
|
||||
];
|
||||
|
||||
# NO TOUCHY
|
||||
system.stateVersion = "26.05";
|
||||
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
gnumake
|
||||
];
|
||||
|
||||
nix.settings = {
|
||||
trusted-users = [ "prouk" ];
|
||||
|
||||
substituters = [
|
||||
"https://cache.nixos.org"
|
||||
"https://nix-community.cachix.org"
|
||||
];
|
||||
trusted-public-keys = [
|
||||
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
|
||||
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||
];
|
||||
};
|
||||
}
|
||||
File renamed without changes.
@@ -0,0 +1,8 @@
|
||||
{ pkgs, inputs, ... }:
|
||||
{
|
||||
programs.niri.enable = true;
|
||||
|
||||
environment.systemPackages = [
|
||||
inputs.xwayland-satellite.packages.${pkgs.stdenv.hostPlatform.system}.default
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
let
|
||||
# Same wallpaper niri displays (see home/dotfiles.nix).
|
||||
wallpaper = ../../assets/wallpaper.png;
|
||||
|
||||
sddmTheme =
|
||||
(pkgs.sddm-astronaut.override {
|
||||
themeConfig = {
|
||||
Background = "Backgrounds/wallpaper.png";
|
||||
CropBackground = "true";
|
||||
};
|
||||
}).overrideAttrs
|
||||
(old: {
|
||||
postInstall = (old.postInstall or "") + ''
|
||||
chmod u+w $out/share/sddm/themes/sddm-astronaut-theme/Backgrounds
|
||||
install -Dm644 ${wallpaper} $out/share/sddm/themes/sddm-astronaut-theme/Backgrounds/wallpaper.png
|
||||
'';
|
||||
});
|
||||
|
||||
# Weston (the greeter compositor) must use the same modes as niri
|
||||
# (home/config/niri/outputs.kdl), otherwise the monitors do a full
|
||||
# modeset when niri takes over, causing a black screen on login.
|
||||
xkb = config.services.xserver.xkb;
|
||||
westonIni = (pkgs.formats.iniWithGlobalSection { }).generate "weston.ini" {
|
||||
sections = {
|
||||
libinput = {
|
||||
enable-tap = config.services.libinput.mouse.tapping;
|
||||
left-handed = config.services.libinput.mouse.leftHanded;
|
||||
};
|
||||
keyboard = {
|
||||
keymap_model = xkb.model;
|
||||
keymap_layout = xkb.layout;
|
||||
keymap_variant = xkb.variant;
|
||||
keymap_options = xkb.options;
|
||||
};
|
||||
};
|
||||
};
|
||||
westonOutputs = pkgs.writeText "weston-outputs.ini" ''
|
||||
[output]
|
||||
name=DP-2
|
||||
mode=2560x1440@240
|
||||
|
||||
[output]
|
||||
name=DP-3
|
||||
mode=1920x1080@144
|
||||
transform=rotate-90
|
||||
'';
|
||||
westonConfig = pkgs.runCommand "weston.ini" { } ''
|
||||
cat ${westonIni} > $out
|
||||
echo >> $out
|
||||
cat ${westonOutputs} >> $out
|
||||
'';
|
||||
in
|
||||
{
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland = {
|
||||
enable = true;
|
||||
compositorCommand = "${lib.getExe pkgs.weston} --shell=kiosk -c ${westonConfig}";
|
||||
};
|
||||
package = pkgs.kdePackages.sddm;
|
||||
theme = "sddm-astronaut-theme";
|
||||
extraPackages = [ sddmTheme ];
|
||||
};
|
||||
|
||||
environment.systemPackages = [ sddmTheme ];
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
{ ... }:
|
||||
{
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
};
|
||||
}
|
||||
@@ -1,10 +0,0 @@
|
||||
{ ... }:
|
||||
{
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
imports = [
|
||||
./nvidia.nix
|
||||
];
|
||||
}
|
||||
@@ -8,7 +8,7 @@
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
jack.enable = false;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
File renamed without changes.
@@ -0,0 +1,4 @@
|
||||
{ ... }:
|
||||
{
|
||||
hardware.graphics.enable = true;
|
||||
}
|
||||
@@ -6,15 +6,19 @@
|
||||
hardware.nvidia = {
|
||||
branch = "bleeding_edge";
|
||||
modesetting.enable = true;
|
||||
powerManagement.enable = false;
|
||||
powerManagement.finegrained = false;
|
||||
open = true;
|
||||
nvidiaSettings = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
egl-wayland
|
||||
lact
|
||||
libva-utils
|
||||
nvidia-vaapi-driver
|
||||
nvtopPackages.nvidia
|
||||
];
|
||||
|
||||
# LACT GPU control daemon
|
||||
systemd.packages = with pkgs; [ lact ];
|
||||
systemd.services.lactd.wantedBy = [ "multi-user.target" ];
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
{ ... }:
|
||||
{
|
||||
services.udisks2.enable = true;
|
||||
}
|
||||
File renamed without changes.
@@ -0,0 +1,10 @@
|
||||
{ ... }:
|
||||
{
|
||||
programs = {
|
||||
steam.enable = true;
|
||||
gamescope = {
|
||||
enable = true;
|
||||
capSysNice = false;
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{ ... }:
|
||||
{
|
||||
# nh: nicer frontend for nixos-rebuild / nix-collect-garbage.
|
||||
# Cleanup stays on nix.gc (see system/nix.nix) to avoid two GC timers.
|
||||
programs.nh = {
|
||||
enable = true;
|
||||
clean.enable = true;
|
||||
clean.extraArgs = "--keep-since 4d --keep 3";
|
||||
flake = "/home/prouk/flake";
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs.obs-studio = {
|
||||
enable = true;
|
||||
package = (
|
||||
pkgs.obs-studio.override {
|
||||
cudaSupport = true;
|
||||
}
|
||||
);
|
||||
enableVirtualCamera = true;
|
||||
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
wlrobs
|
||||
obs-pipewire-audio-capture
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -1,16 +0,0 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs = {
|
||||
steam.enable = true;
|
||||
gamescope = {
|
||||
enable = true;
|
||||
capSysNice = false;
|
||||
};
|
||||
};
|
||||
environment.systemPackages = with pkgs; [
|
||||
SDL2
|
||||
protonup-rs
|
||||
protontricks
|
||||
winetricks
|
||||
];
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
boot = {
|
||||
# TODO: drop the extend once NixOS/nixpkgs#575861 lands (v4l2loopback ships
|
||||
# depmod files that conflict with the kernel's in linux-*-modules).
|
||||
kernelPackages = pkgs.linuxPackages_latest.extend (
|
||||
_: prev: {
|
||||
v4l2loopback = prev.v4l2loopback.overrideAttrs (old: {
|
||||
installFlags = (old.installFlags or [ ]) ++ [ "DEPMOD=true" ];
|
||||
});
|
||||
}
|
||||
);
|
||||
|
||||
loader = {
|
||||
systemd-boot.enable = true;
|
||||
efi.canTouchEfiVariables = true;
|
||||
# Skip the boot menu; hold Space while booting to show it.
|
||||
timeout = 0;
|
||||
# Keep /boot from filling up with old generations.
|
||||
systemd-boot.configurationLimit = 5;
|
||||
};
|
||||
|
||||
# Quiet boot
|
||||
consoleLogLevel = 3;
|
||||
initrd.verbose = false;
|
||||
kernelParams = [
|
||||
"quiet"
|
||||
"udev.log_level=3"
|
||||
"rd.udev.log_level=3"
|
||||
"systemd.show_status=auto"
|
||||
"rd.systemd.show_status=auto"
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,4 @@
|
||||
{ ... }:
|
||||
{
|
||||
time.timeZone = "Europe/Paris";
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
{ ... }:
|
||||
{
|
||||
networking = {
|
||||
hostName = "prouk";
|
||||
networkmanager.enable = true;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
{ ... }:
|
||||
{
|
||||
nix.settings = {
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
trusted-users = [ "prouk" ];
|
||||
|
||||
substituters = [
|
||||
"https://cache.nixos.org"
|
||||
"https://nix-community.cachix.org"
|
||||
];
|
||||
trusted-public-keys = [
|
||||
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
|
||||
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||
];
|
||||
};
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# Housekeeping
|
||||
nix.optimise.automatic = true;
|
||||
|
||||
# Run unpatched dynamic binaries.
|
||||
programs.nix-ld.enable = true;
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
# Required so fish is registered in /etc/shells and gets the NixOS environment.
|
||||
programs.fish.enable = true;
|
||||
|
||||
users.users.prouk = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" ];
|
||||
shell = pkgs.fish;
|
||||
};
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
programs.niri.enable = true;
|
||||
programs.xwayland.enable = true;
|
||||
|
||||
environment.variables = {
|
||||
NIXOS_OZONE_WLEGL = "1";
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
alacritty
|
||||
];
|
||||
}
|
||||
Reference in new issue
Block a user