fibe fixed my dude
This commit is contained in:
80
CLAUDE.md
Normal file
80
CLAUDE.md
Normal file
@@ -0,0 +1,80 @@
|
||||
# CLAUDE.md
|
||||
|
||||
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
|
||||
|
||||
## Build Commands
|
||||
|
||||
```bash
|
||||
# Rebuild and switch to main system (default specialization)
|
||||
ns # alias for: nh os switch --specialisation 00-main-system
|
||||
|
||||
# Update flake inputs and commit lock file
|
||||
nu # alias for: (cd ~/nixos-dots && nix flake update --commit-lock-file)
|
||||
|
||||
# Edit configuration in Emacs
|
||||
ne # alias for: emacsclient -c ~/nixos-dots/configuration.nix
|
||||
|
||||
# Direct rebuild commands (if not using nh aliases)
|
||||
sudo nixos-rebuild switch --flake .#mrfluffyPC
|
||||
sudo nixos-rebuild switch --flake .#mrfluffyLaptop
|
||||
```
|
||||
|
||||
## Architecture
|
||||
|
||||
### Multi-Host / Multi-User System
|
||||
|
||||
This is a NixOS flake configuration targeting two machines (`mrfluffyPC`, `mrfluffyLaptop`) with three users (`mrfluffy`, `work`, `game`). The `systemName` variable (`"pc"` or `"laptop"`) is passed through `specialArgs` to enable hardware-conditional configuration.
|
||||
|
||||
### Specializations
|
||||
|
||||
Two boot specializations exist in `configuration.nix`:
|
||||
- **`00-main-system`**: Default desktop environment with Hyprland, full dev tooling
|
||||
- **`01-steam`**: Gaming mode with Gamescope, Steam Big Picture, auto-login to `game` user
|
||||
|
||||
### Directory Structure
|
||||
|
||||
```
|
||||
flake.nix # Flake inputs and nixosConfigurations
|
||||
configuration.nix # Entry point: users, home-manager, specializations
|
||||
hardware-configuration.nix
|
||||
system/ # NixOS modules (boot, hardware, services, packages)
|
||||
├── boot.nix # Bootloader, kernel config (laptop/pc conditional)
|
||||
├── hardware.nix # GPU drivers (Intel for laptop, AMD for PC)
|
||||
├── nixOSPkgs.nix # System packages (~2300 lines)
|
||||
├── services.nix # System services (greetd, pipewire, etc.)
|
||||
└── specialisation/ # Boot mode configs
|
||||
home/ # Home Manager user configs
|
||||
├── mrfluffy.nix # Main user (imports dots/, stylix, services)
|
||||
├── work.nix # Work user
|
||||
├── game.nix # Gaming user
|
||||
├── homePkgs.nix # User packages
|
||||
└── stylix.nix # Unified theming (base16, fonts, cursors)
|
||||
dots/ # Application dotfiles as Nix modules
|
||||
├── hyprland.nix # Primary window manager
|
||||
├── waybar.nix # Status bar
|
||||
├── foot.nix # Terminal
|
||||
├── zsh.nix # Shell config with aliases
|
||||
└── doom/ # Doom Emacs config (raw files)
|
||||
assets/Wallpapers/ # Wallpaper images
|
||||
```
|
||||
|
||||
### Window Manager Selection
|
||||
|
||||
Set in `flake.nix` via `window_manager` variable (options: `"hyprland"`, `"river"`, `"niri"`, `"all"`). Currently set to `"hyprland"`. This variable is passed to modules for conditional WM configuration.
|
||||
|
||||
### Theming
|
||||
|
||||
Stylix + nix-colors provide unified theming across all applications:
|
||||
- Color scheme: `hardcore` (base00: `#141414`)
|
||||
- Configured in `home/stylix.nix`
|
||||
|
||||
### Conditional Hardware Config
|
||||
|
||||
Use the `systemName` variable (`"laptop"` or `"pc"`) for hardware-specific code:
|
||||
```nix
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
# ... use lib.mkIf for conditional values
|
||||
```
|
||||
@@ -3,14 +3,38 @@
|
||||
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
window_manager,
|
||||
systemName,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
# Common groups for main users (mrfluffy, work)
|
||||
defaultUserGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
"video"
|
||||
"render"
|
||||
"docker"
|
||||
"libvirt"
|
||||
"input"
|
||||
"seat"
|
||||
"dialout"
|
||||
];
|
||||
|
||||
# Groups for game user (no wheel for security - has empty password)
|
||||
gameUserGroups = [
|
||||
"video"
|
||||
"render"
|
||||
"input"
|
||||
"seat"
|
||||
"networkmanager"
|
||||
"dialout"
|
||||
];
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
@@ -24,9 +48,7 @@
|
||||
#inputs.niri.nixosModules.niri
|
||||
];
|
||||
|
||||
##############################################################################
|
||||
# Nix settings
|
||||
##############################################################################
|
||||
# ─── Nix settings ───────────────────────────────────────────────────────────
|
||||
nix.settings = {
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
@@ -36,9 +58,7 @@
|
||||
auto-optimise-store = true;
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Users
|
||||
##############################################################################
|
||||
# ─── Users ──────────────────────────────────────────────────────────────────
|
||||
programs.zsh.enable = true;
|
||||
users = {
|
||||
users = {
|
||||
@@ -56,17 +76,7 @@
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
createHome = true;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
"video"
|
||||
"render"
|
||||
"docker"
|
||||
"libvirt"
|
||||
"input"
|
||||
"seat"
|
||||
"dialout"
|
||||
];
|
||||
extraGroups = defaultUserGroups;
|
||||
packages = with pkgs; [ ];
|
||||
};
|
||||
|
||||
@@ -74,34 +84,17 @@
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
createHome = true;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
"video"
|
||||
"render"
|
||||
"docker"
|
||||
"libvirt"
|
||||
"input"
|
||||
"seat"
|
||||
"dialout"
|
||||
];
|
||||
extraGroups = defaultUserGroups;
|
||||
packages = with pkgs; [ ];
|
||||
};
|
||||
|
||||
game = {
|
||||
isNormalUser = true;
|
||||
description = "Dedicated gaming user (auto-login in Steam specialisation)";
|
||||
shell = pkgs.bash;
|
||||
createHome = true;
|
||||
password = ""; # no password
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"video"
|
||||
"render"
|
||||
"input"
|
||||
"seat"
|
||||
"networkmanager"
|
||||
"dialout"
|
||||
];
|
||||
hashedPassword = ""; # no password - removed wheel group for security
|
||||
extraGroups = gameUserGroups;
|
||||
home = "/home/game";
|
||||
};
|
||||
};
|
||||
@@ -111,9 +104,7 @@
|
||||
];
|
||||
|
||||
};
|
||||
##############################################################################
|
||||
# Home-Manager
|
||||
##############################################################################
|
||||
# ─── Home-Manager ───────────────────────────────────────────────────────────
|
||||
home-manager = {
|
||||
extraSpecialArgs = { inherit inputs window_manager systemName; };
|
||||
users = {
|
||||
@@ -123,9 +114,7 @@
|
||||
};
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Environment
|
||||
##############################################################################
|
||||
# ─── Environment ────────────────────────────────────────────────────────────
|
||||
environment = {
|
||||
sessionVariables = {
|
||||
ZDOTDIR = "$HOME/.config/zsh";
|
||||
@@ -150,17 +139,13 @@
|
||||
];
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Nixpkgs policy
|
||||
##############################################################################
|
||||
# ─── Nixpkgs policy ─────────────────────────────────────────────────────────
|
||||
nixpkgs.config = {
|
||||
allowUnfree = true;
|
||||
permittedInsecurePackages = [ ];
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# decky
|
||||
##############################################################################
|
||||
# ─── Decky ──────────────────────────────────────────────────────────────────
|
||||
nixpkgs.overlays = [
|
||||
inputs.jovian.overlays.default
|
||||
];
|
||||
@@ -173,9 +158,7 @@
|
||||
# extraPythonPackages = ps: with ps; [ some-python-package ];
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# State version
|
||||
##############################################################################
|
||||
# ─── State version ──────────────────────────────────────────────────────────
|
||||
system.stateVersion = "24.11"; # Did you read the comment?
|
||||
|
||||
specialisation = {
|
||||
@@ -190,9 +173,7 @@
|
||||
"00-main-system" = {
|
||||
configuration = {
|
||||
#boot.loader.systemd-boot.sortKey = lib.mkDefault "00000000000-main";
|
||||
##############################################################################
|
||||
# Imports
|
||||
##############################################################################
|
||||
# ─── Imports ─────────────────────────────────────────────────────────────────
|
||||
imports = [
|
||||
./system/services.nix
|
||||
./system/nixOSPkgs.nix
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
{ config,
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
pkgs,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
|
||||
@@ -8,6 +8,9 @@
|
||||
...
|
||||
}:
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
|
||||
hypr-package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland;
|
||||
hypr-portal =
|
||||
inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland;
|
||||
@@ -35,9 +38,7 @@ in
|
||||
];
|
||||
|
||||
settings = {
|
||||
##########################################################################
|
||||
# Monitors
|
||||
##########################################################################
|
||||
# ─── Monitors ────────────────────────────────────────────────────────────────
|
||||
source = [
|
||||
"./dms/outputs.conf"
|
||||
#"./dms/cursor.conf"
|
||||
@@ -86,9 +87,7 @@ in
|
||||
# transform = 0;
|
||||
# };
|
||||
|
||||
##########################################################################
|
||||
# Autostart
|
||||
##########################################################################
|
||||
# ─── Autostart ───────────────────────────────────────────────────────────────
|
||||
|
||||
# Autostart necessary processes (like notifications daemons, status bars, etc.)
|
||||
# Or execute your favorite apps at launch like this:
|
||||
@@ -113,9 +112,7 @@ in
|
||||
# ++ lib.optional (systemName == "pc")
|
||||
# "swaybg -o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}";
|
||||
|
||||
##########################################################################
|
||||
# Plugins
|
||||
##########################################################################
|
||||
# ─── Plugins ─────────────────────────────────────────────────────────────────
|
||||
|
||||
plugin = {
|
||||
split-monitor-workspaces = {
|
||||
@@ -129,18 +126,14 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
##########################################################################
|
||||
# Environment
|
||||
##########################################################################
|
||||
# ─── Environment ─────────────────────────────────────────────────────────────
|
||||
|
||||
env = [
|
||||
"XCURSOR_SIZE, 24"
|
||||
"HYPRCURSOR_SIZE, 24"
|
||||
];
|
||||
|
||||
##########################################################################
|
||||
# General / Render / Decoration / Animations
|
||||
##########################################################################
|
||||
# ─── General / Render / Decoration / Animations ─────────────────────────────
|
||||
|
||||
# https://wiki.hyprland.org/Configuring/Variables/
|
||||
# https://wiki.hyprland.org/Configuring/Variables/#general
|
||||
@@ -218,9 +211,7 @@ in
|
||||
];
|
||||
};
|
||||
|
||||
##########################################################################
|
||||
# Layouts
|
||||
##########################################################################
|
||||
# ─── Layouts ─────────────────────────────────────────────────────────────────
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||
dwindle = {
|
||||
@@ -236,9 +227,7 @@ in
|
||||
new_on_top = true;
|
||||
};
|
||||
|
||||
##########################################################################
|
||||
# Misc / Input / Gestures / Devices
|
||||
##########################################################################
|
||||
# ─── Misc / Input / Gestures / Devices ───────────────────────────────────────
|
||||
|
||||
# https://wiki.hyprland.org/Configuring/Variables/#misc
|
||||
misc = {
|
||||
@@ -251,8 +240,8 @@ in
|
||||
# https://wiki.hyprland.org/Configuring/Variables/#input
|
||||
input = {
|
||||
kb_layout = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "laptop") "ie")
|
||||
(lib.mkIf (systemName == "pc") "us")
|
||||
(lib.mkIf isLaptop "ie")
|
||||
(lib.mkIf isPc "us")
|
||||
];
|
||||
repeat_rate = 40;
|
||||
repeat_delay = 500;
|
||||
@@ -281,9 +270,7 @@ in
|
||||
sensitivity = -0.5;
|
||||
};
|
||||
|
||||
##########################################################################
|
||||
# Binds
|
||||
##########################################################################
|
||||
# ─── Binds ───────────────────────────────────────────────────────────────────
|
||||
|
||||
bind = [
|
||||
# Launcher / apps
|
||||
@@ -394,9 +381,7 @@ in
|
||||
|
||||
binds = [ ];
|
||||
|
||||
##########################################################################
|
||||
# Rules (windows / workspaces)
|
||||
##########################################################################
|
||||
# ─── Rules (windows / workspaces) ────────────────────────────────────────────
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
||||
# See https://wiki.hyprland.org/Configuring/Workspace-Rules/ for workspace rules
|
||||
|
||||
@@ -7,6 +7,10 @@
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
services = {
|
||||
hypridle = {
|
||||
@@ -24,19 +28,19 @@
|
||||
on-timeout = "loginctl lock-session";
|
||||
}
|
||||
]
|
||||
++ lib.optional (systemName == "laptop") {
|
||||
++ lib.optional isLaptop {
|
||||
timeout = 700;
|
||||
on-timeout = "hyprctl dispatch dpms off"; # Turns off all displays
|
||||
on-resume = "hyprctl dispatch dpms on"; # Turns displays back on
|
||||
on-timeout = "hyprctl dispatch dpms off";
|
||||
on-resume = "hyprctl dispatch dpms on";
|
||||
}
|
||||
++ lib.optional (systemName == "laptop") {
|
||||
++ lib.optional isLaptop {
|
||||
timeout = 800;
|
||||
on-timeout = "systemctl suspend-then-hibernate";
|
||||
}
|
||||
++ lib.optional (systemName == "pc") {
|
||||
timeout = 700; # Adjust timeout as needed (in seconds)
|
||||
on-timeout = "hyprctl dispatch dpms off"; # Turns off all displays
|
||||
on-resume = "hyprctl dispatch dpms on"; # Turns displays back on
|
||||
++ lib.optional isPc {
|
||||
timeout = 700;
|
||||
on-timeout = "hyprctl dispatch dpms off";
|
||||
on-resume = "hyprctl dispatch dpms on";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -162,7 +162,7 @@
|
||||
|
||||
# You can change how the focus ring looks.
|
||||
focus-ring = {
|
||||
#omment this line to disable the focus ring.
|
||||
# Uncomment this line to disable the focus ring.
|
||||
# off
|
||||
|
||||
# How many logical pixels the ring extends out from the windows.
|
||||
|
||||
@@ -1,11 +1,16 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
window_manager,
|
||||
systemName,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
wayland.windowManager.river = {
|
||||
enable = window_manager == "river" || window_manager == "all";
|
||||
@@ -26,21 +31,19 @@
|
||||
editor="emacs"
|
||||
|
||||
riverctl input "pointer-2362-8197-ASUP1204:00_093A:2005_Touchpad" tap enabled
|
||||
riverctl keyboard-layout -options "grp:ctrl_space_toggle" ${
|
||||
if systemName == "laptop" then "ie,us" else "us"
|
||||
riverctl keyboard-layout -options "grp:ctrl_space_toggle" ${
|
||||
if isLaptop
|
||||
then "ie,us"
|
||||
else "us"
|
||||
}
|
||||
|
||||
#riverctl spawn 'export XDG_CURRENT_DESKTOP=river'
|
||||
#riverctl spawn 'systemctl --user restart xdg-desktop-portal'
|
||||
riverctl spawn 'dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP'
|
||||
riverctl spawn 'swaybg ${
|
||||
# Handle laptop case
|
||||
lib.optionalString (systemName == "laptop") "-o eDP-1 -i ${../assets/Wallpapers/138.png}"
|
||||
lib.optionalString isLaptop "-o eDP-1 -i ${../assets/Wallpapers/138.png}"
|
||||
}${
|
||||
# Handle PC case (appends to laptop case if needed, but conditions should be mutually exclusive)
|
||||
lib.optionalString (
|
||||
systemName == "pc"
|
||||
) "-o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}"
|
||||
lib.optionalString isPc "-o HDMI-A-1 -i ${../assets/Wallpapers/138.png} -o DP-1 -i ${../assets/Wallpapers/138.png}"
|
||||
}'
|
||||
#riverctl spawn '/home/mrfluffy/.config/script/mic-gain-fix.sh'
|
||||
riverctl spawn 'waybar &'
|
||||
@@ -57,12 +60,9 @@
|
||||
riverctl set-cursor-warp on-focus-change
|
||||
#riverctl xcursor-theme oreo_spark_pink_cursors
|
||||
riverctl spawn '${
|
||||
# Handle laptop case
|
||||
lib.optionalString (systemName == "laptop") "wlr-randr --output eDP-1 --mode 1920x1080@60"
|
||||
lib.optionalString isLaptop "wlr-randr --output eDP-1 --mode 1920x1080@60"
|
||||
}${
|
||||
# Handle PC case (appends to laptop case if needed, but conditions should be mutually exclusive)
|
||||
lib.optionalString (systemName == "pc")
|
||||
"wlr-randr --output DP-1 --mode 2560x1440@144 --pos 1920,0 --output HDMI-A-1 --mode 1920x1080@60 --pos 0,0"
|
||||
lib.optionalString isPc "wlr-randr --output DP-1 --mode 2560x1440@144 --pos 1920,0 --output HDMI-A-1 --mode 1920x1080@60 --pos 0,0"
|
||||
}'
|
||||
|
||||
# This is the example configuration file for river.
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
window_manager,
|
||||
@@ -16,14 +17,12 @@
|
||||
|
||||
#tags button.occupied {
|
||||
color: inherit;
|
||||
background-color: #6a548d
|
||||
background-color: #6a548d;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#tags button.focused {
|
||||
color: #f8f8f2;
|
||||
background-color: #aa86e1 ;
|
||||
background-color: #aa86e1;
|
||||
}
|
||||
|
||||
#tags button.urgent {
|
||||
@@ -119,17 +118,16 @@
|
||||
spacing = 4; # Gaps between modules (4px)
|
||||
# Choose the order of the modules
|
||||
modules-left =
|
||||
if window_manager == "river" then
|
||||
[
|
||||
"river/tags"
|
||||
"custom/media"
|
||||
]
|
||||
else if window_manager == "hyprland" then
|
||||
[
|
||||
"hyprland/workspaces"
|
||||
]
|
||||
else
|
||||
[ ];
|
||||
if window_manager == "river"
|
||||
then [
|
||||
"river/tags"
|
||||
"custom/media"
|
||||
]
|
||||
else if window_manager == "hyprland"
|
||||
then [
|
||||
"hyprland/workspaces"
|
||||
]
|
||||
else [ ];
|
||||
modules-center = [
|
||||
];
|
||||
|
||||
|
||||
68
dots/xdg.nix
68
dots/xdg.nix
@@ -38,40 +38,40 @@
|
||||
|
||||
defaultApplications =
|
||||
let
|
||||
browser = [ "firefox.desktop" ];
|
||||
browser = [ "firefox.desktop" ];
|
||||
fileManager = [ "pcmanfm.desktop" ];
|
||||
editor = [ "emacs.desktop" ];
|
||||
player = [ "mpv.desktop" ];
|
||||
viewer = [ "imv-dir.desktop" ];
|
||||
reader = [ "org.pwmt.zathura.desktop" ];
|
||||
editor = [ "emacs.desktop" ];
|
||||
player = [ "mpv.desktop" ];
|
||||
viewer = [ "imv-dir.desktop" ];
|
||||
reader = [ "org.pwmt.zathura.desktop" ];
|
||||
in {
|
||||
# Documents
|
||||
"application/pdf" = reader;
|
||||
"application/pdf" = reader;
|
||||
"application/epub" = reader;
|
||||
|
||||
# Text / markup
|
||||
"text/plain" = editor;
|
||||
"text/plain" = editor;
|
||||
"application/x-wine-extension-ini" = editor;
|
||||
"text/html" = browser;
|
||||
"text/xml" = browser;
|
||||
"text/html" = browser;
|
||||
"text/xml" = browser;
|
||||
|
||||
# Web / XML-ish
|
||||
"application/json" = browser;
|
||||
"application/xml" = browser;
|
||||
"application/xhtml+xml" = browser;
|
||||
"application/xhtml_xml" = browser;
|
||||
"application/rdf+xml" = browser;
|
||||
"application/rss+xml" = browser;
|
||||
"application/x-extension-htm" = browser;
|
||||
"application/x-extension-html" = browser;
|
||||
"application/json" = browser;
|
||||
"application/xml" = browser;
|
||||
"application/xhtml+xml" = browser;
|
||||
"application/xhtml_xml" = browser;
|
||||
"application/rdf+xml" = browser;
|
||||
"application/rss+xml" = browser;
|
||||
"application/x-extension-htm" = browser;
|
||||
"application/x-extension-html" = browser;
|
||||
"application/x-extension-shtml" = browser;
|
||||
"application/x-extension-xht" = browser;
|
||||
"application/x-extension-xht" = browser;
|
||||
"application/x-extension-xhtml" = browser;
|
||||
|
||||
# URL schemes
|
||||
"x-scheme-handler/about" = browser;
|
||||
"x-scheme-handler/ftp" = browser;
|
||||
"x-scheme-handler/http" = browser;
|
||||
"x-scheme-handler/ftp" = browser;
|
||||
"x-scheme-handler/http" = browser;
|
||||
"x-scheme-handler/https" = browser;
|
||||
|
||||
# Files / directories
|
||||
@@ -80,20 +80,20 @@
|
||||
|
||||
# Audio
|
||||
"audio/mpeg" = player;
|
||||
"audio/aac" = player;
|
||||
"audio/aac" = player;
|
||||
"audio/flac" = player;
|
||||
"audio/wav" = player;
|
||||
"audio/wav" = player;
|
||||
|
||||
# Video
|
||||
"video/mp4" = player;
|
||||
"video/vnd.mpegurl" = player;
|
||||
"video/x-matroska" = player;
|
||||
"video/mp4" = player;
|
||||
"video/vnd.mpegurl" = player;
|
||||
"video/x-matroska" = player;
|
||||
"application/x-mpegURL" = player;
|
||||
|
||||
# Images
|
||||
"image/gif" = viewer;
|
||||
"image/gif" = viewer;
|
||||
"image/jpeg" = viewer;
|
||||
"image/png" = viewer;
|
||||
"image/png" = viewer;
|
||||
"image/webp" = viewer;
|
||||
};
|
||||
};
|
||||
@@ -102,13 +102,13 @@
|
||||
enable = true;
|
||||
createDirectories = true;
|
||||
|
||||
download = "${config.home.homeDirectory}/Downloads";
|
||||
documents = "${config.home.homeDirectory}/Documents";
|
||||
desktop = "${config.home.homeDirectory}/Desktop";
|
||||
videos = "${config.home.homeDirectory}/Videos";
|
||||
pictures = "${config.home.homeDirectory}/Pictures";
|
||||
music = "${config.home.homeDirectory}/Music";
|
||||
templates = "${config.home.homeDirectory}/.local/share/templates";
|
||||
download = "${config.home.homeDirectory}/Downloads";
|
||||
documents = "${config.home.homeDirectory}/Documents";
|
||||
desktop = "${config.home.homeDirectory}/Desktop";
|
||||
videos = "${config.home.homeDirectory}/Videos";
|
||||
pictures = "${config.home.homeDirectory}/Pictures";
|
||||
music = "${config.home.homeDirectory}/Music";
|
||||
templates = "${config.home.homeDirectory}/.local/share/templates";
|
||||
publicShare = "${config.home.homeDirectory}/.local/share/public";
|
||||
};
|
||||
|
||||
|
||||
90
dots/zsh.nix
90
dots/zsh.nix
@@ -1,13 +1,13 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
programs.zsh = {
|
||||
enable = true;
|
||||
dotDir = "${config.xdg.configHome}/zsh";
|
||||
enable = true;
|
||||
dotDir = "${config.xdg.configHome}/zsh";
|
||||
|
||||
plugins = [
|
||||
# pkgs.zsh-autosuggestions
|
||||
@@ -15,7 +15,7 @@
|
||||
];
|
||||
|
||||
autosuggestion = {
|
||||
enable = true;
|
||||
enable = true;
|
||||
highlight = "fg=#64677a,bold,underline";
|
||||
};
|
||||
|
||||
@@ -24,51 +24,51 @@
|
||||
};
|
||||
|
||||
sessionVariables = {
|
||||
LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
|
||||
HISTSIZE = 3000;
|
||||
SAVEHIST = 3000;
|
||||
CARGO_HOME = "$XDG_DATA_HOME/cargo";
|
||||
GNUPGHOME = "$XDG_DATA_HOME/gnupg";
|
||||
GOPATH = "$XDG_DATA_HOME/go";
|
||||
GRADLE_USER_HOME = "$XDG_DATA_HOME/gradle";
|
||||
IPYTHONDIR = "$XDG_CONFIG_HOME/ipython";
|
||||
JUPYTER_CONFIG_DIR = "$XDG_CONFIG_HOME/jupyter";
|
||||
LESSHISTFILE = "$XDG_CACHE_HOME/less/history";
|
||||
NUGET_PACKAGES = "$XDG_CACHE_HOME/NuGetPackages";
|
||||
PYTHONSTARTUP = "$XDG_CONFIG_HOME/python/pythonrc";
|
||||
KERAS_HOME = "$XDG_STATE_HOME/keras";
|
||||
RUSTUP_HOME = "$XDG_DATA_HOME/rustup";
|
||||
XCOMPOSECACHE = "$XDG_CACHE_HOME/X11/xcompose";
|
||||
SSB_HOME = "$XDG_DATA_HOME/zoom";
|
||||
HISTFILE = "$XDG_STATE_HOME/zsh/history";
|
||||
LD_LIBRARY_PATH = "/run/current-system/sw/share/nix-ld/lib";
|
||||
HISTSIZE = 3000;
|
||||
SAVEHIST = 3000;
|
||||
CARGO_HOME = "$XDG_DATA_HOME/cargo";
|
||||
GNUPGHOME = "$XDG_DATA_HOME/gnupg";
|
||||
GOPATH = "$XDG_DATA_HOME/go";
|
||||
GRADLE_USER_HOME = "$XDG_DATA_HOME/gradle";
|
||||
IPYTHONDIR = "$XDG_CONFIG_HOME/ipython";
|
||||
JUPYTER_CONFIG_DIR = "$XDG_CONFIG_HOME/jupyter";
|
||||
LESSHISTFILE = "$XDG_CACHE_HOME/less/history";
|
||||
NUGET_PACKAGES = "$XDG_CACHE_HOME/NuGetPackages";
|
||||
PYTHONSTARTUP = "$XDG_CONFIG_HOME/python/pythonrc";
|
||||
KERAS_HOME = "$XDG_STATE_HOME/keras";
|
||||
RUSTUP_HOME = "$XDG_DATA_HOME/rustup";
|
||||
XCOMPOSECACHE = "$XDG_CACHE_HOME/X11/xcompose";
|
||||
SSB_HOME = "$XDG_DATA_HOME/zoom";
|
||||
HISTFILE = "$XDG_STATE_HOME/zsh/history";
|
||||
};
|
||||
|
||||
shellAliases = {
|
||||
ns = "nh os switch --specialisation 00-main-system";
|
||||
ns = "nh os switch --specialisation 00-main-system";
|
||||
nu = "(cd ~/nixos-dots && nix flake update --commit-lock-file) && echo 'flake.lock updated'";
|
||||
ne = "emacsclient -c ~/nixos-dots/configuration.nix";
|
||||
ne = "emacsclient -c ~/nixos-dots/configuration.nix";
|
||||
|
||||
ls = "exa -lag --icons";
|
||||
upload = "~/.config/script/upload.sh";
|
||||
record = "~/.config/script/record.sh";
|
||||
speak = "~/.config/script/wisper.sh";
|
||||
vim = "nvim";
|
||||
cat = "bat";
|
||||
anime = "~/repos/ani-cli/ani-cli";
|
||||
hentai = "~/repos/and-scripts/fap-cli";
|
||||
manga = "manga-cli";
|
||||
yt = "~/repos/ytfzf/ytfzf --thumb-viewer='kitty' -t";
|
||||
cd = "z";
|
||||
rm = "rip";
|
||||
df = "duf";
|
||||
time = "hyperfine";
|
||||
kami = "~/Documents/Rust/kami/target/release/kami";
|
||||
calc = "cpc";
|
||||
pdf = "mupdf";
|
||||
emacs = "emacs";
|
||||
river = "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river && river";
|
||||
cp = "xcp";
|
||||
wget = "wget --hsts-file=$XDG_DATA_HOME/wget-hsts";
|
||||
ls = "exa -lag --icons";
|
||||
upload = "~/.config/script/upload.sh";
|
||||
record = "~/.config/script/record.sh";
|
||||
speak = "~/.config/script/wisper.sh";
|
||||
vim = "nvim";
|
||||
cat = "bat";
|
||||
anime = "~/repos/ani-cli/ani-cli";
|
||||
hentai = "~/repos/and-scripts/fap-cli";
|
||||
manga = "manga-cli";
|
||||
yt = "~/repos/ytfzf/ytfzf --thumb-viewer='kitty' -t";
|
||||
cd = "z";
|
||||
rm = "rip";
|
||||
df = "duf";
|
||||
time = "hyperfine";
|
||||
kami = "~/Documents/Rust/kami/target/release/kami";
|
||||
calc = "cpc";
|
||||
pdf = "mupdf";
|
||||
emacs = "emacs";
|
||||
river = "dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=river && river";
|
||||
cp = "xcp";
|
||||
wget = "wget --hsts-file=$XDG_DATA_HOME/wget-hsts";
|
||||
};
|
||||
|
||||
initContent = ''
|
||||
|
||||
@@ -61,9 +61,8 @@
|
||||
};
|
||||
vicinae = {
|
||||
url = "github:vicinaehq/vicinae";
|
||||
#inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
# ... your existing inputs ...
|
||||
jovian = {
|
||||
url = "github:Jovian-Experiments/Jovian-NixOS";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
||||
@@ -10,33 +10,40 @@
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules =
|
||||
[ ]
|
||||
++ (lib.optionals (systemName == "pc") [
|
||||
assertions = [{
|
||||
assertion = builtins.elem systemName [ "laptop" "pc" ];
|
||||
message = "systemName must be either 'laptop' or 'pc', got: ${systemName}";
|
||||
}];
|
||||
|
||||
boot.initrd.availableKernelModules = [ ]
|
||||
++ lib.optionals isPc [
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"nvme"
|
||||
"usb_storage"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
])
|
||||
++ (lib.optionals (systemName == "laptop") [
|
||||
]
|
||||
++ lib.optionals isLaptop [
|
||||
"vmd"
|
||||
"xhci_pci"
|
||||
"nvme"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
]);
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules =
|
||||
[ ]
|
||||
++ (lib.optionals (systemName == "pc") [ "kvm-amd" "btusb"])
|
||||
++ (lib.optionals (systemName == "laptop") [ "kvm-intel" ]);
|
||||
boot.kernelModules = [ ]
|
||||
++ lib.optionals isPc [ "kvm-amd" "btusb" ]
|
||||
++ lib.optionals isLaptop [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
boot.kernelParams = [
|
||||
# Most common working combination in 2024/2025
|
||||
@@ -45,22 +52,22 @@
|
||||
];
|
||||
|
||||
fileSystems."/" = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
device = "/dev/disk/by-uuid/fdcbb840-4b35-4023-a048-599b0c5161d6";
|
||||
fsType = "btrfs";
|
||||
})
|
||||
(lib.mkIf (systemName == "laptop") {
|
||||
(lib.mkIf isLaptop {
|
||||
device = "/dev/disk/by-uuid/6aa7c67d-a0a5-4928-b16b-9c7991fee7ab";
|
||||
fsType = "ext4";
|
||||
})
|
||||
];
|
||||
|
||||
fileSystems."/boot" = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
device = "/dev/disk/by-uuid/E1B6-9089";
|
||||
fsType = "vfat";
|
||||
})
|
||||
(lib.mkIf (systemName == "laptop") {
|
||||
(lib.mkIf isLaptop {
|
||||
device = "/dev/disk/by-uuid/FF4B-819D";
|
||||
fsType = "vfat";
|
||||
options = [
|
||||
@@ -71,20 +78,21 @@
|
||||
];
|
||||
|
||||
fileSystems."/home" = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
device = "/dev/disk/by-uuid/d226a8ed-10eb-452e-9284-1ff994a7f179";
|
||||
fsType = "btrfs";
|
||||
})
|
||||
];
|
||||
|
||||
fileSystems."/home/game/Games" = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
device = "/dev/disk/by-uuid/54188f21-d525-4681-a9d4-b798363eef17";
|
||||
fsType = "ext4";
|
||||
})
|
||||
];
|
||||
|
||||
|
||||
#fileSystems."/server" = lib.mkIf (systemName == "pc") { # or remove the mkIf if you want it on both
|
||||
#fileSystems."/server" = lib.mkIf isPc { # or remove the mkIf if you want it on both
|
||||
# device = "//192.168.1.8/mrfluffy"; # adjust the share name if it’s not the home share
|
||||
# fsType = "cifs";
|
||||
# options = let
|
||||
@@ -107,18 +115,13 @@
|
||||
# ];
|
||||
#};
|
||||
|
||||
swapDevices =
|
||||
[ ]
|
||||
++ (lib.optionals (systemName == "pc") [
|
||||
{
|
||||
device = "/dev/disk/by-uuid/ccf41b96-c45f-47e0-8541-cd865f5d2ec6";
|
||||
}
|
||||
])
|
||||
++ (lib.optionals (systemName == "laptop") [
|
||||
{
|
||||
device = "/dev/disk/by-uuid/b416c3bd-861b-4b0c-aa84-6962b2e6a47d";
|
||||
}
|
||||
]);
|
||||
swapDevices = [ ]
|
||||
++ lib.optionals isPc [
|
||||
{ device = "/dev/disk/by-uuid/ccf41b96-c45f-47e0-8541-cd865f5d2ec6"; }
|
||||
]
|
||||
++ lib.optionals isLaptop [
|
||||
{ device = "/dev/disk/by-uuid/b416c3bd-861b-4b0c-aa84-6962b2e6a47d"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
@@ -130,10 +133,10 @@
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
})
|
||||
(lib.mkIf (systemName == "laptop") {
|
||||
(lib.mkIf isLaptop {
|
||||
cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
})
|
||||
];
|
||||
|
||||
66
home/common.nix
Normal file
66
home/common.nix
Normal file
@@ -0,0 +1,66 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
window_manager,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [
|
||||
# Core theming & integrations
|
||||
inputs.nix-colors.homeManagerModules.default
|
||||
inputs.stylix.homeModules.stylix
|
||||
inputs.nixcord.homeModules.nixcord
|
||||
|
||||
# Local modules
|
||||
./sessionVars.nix
|
||||
./stylix.nix
|
||||
./homePkgs.nix
|
||||
./services.nix
|
||||
|
||||
# Dots
|
||||
../dots/foot.nix
|
||||
../dots/waybar.nix
|
||||
../dots/zsh.nix
|
||||
../dots/nixcord.nix
|
||||
../dots/xdg.nix
|
||||
../dots/river.nix
|
||||
../dots/hyprland.nix
|
||||
../dots/hyprpaper.nix
|
||||
../dots/caelestia.nix
|
||||
../dots/dankMeterialShell.nix
|
||||
];
|
||||
|
||||
# Common state version
|
||||
home.stateVersion = "23.11";
|
||||
|
||||
# Common GTK settings
|
||||
gtk = {
|
||||
enable = true;
|
||||
iconTheme = {
|
||||
name = "Reversal-black-dark";
|
||||
package = pkgs.reversal-icon-theme.override { allColorVariants = true; };
|
||||
};
|
||||
};
|
||||
|
||||
# Common packages for all users
|
||||
home.packages = with pkgs; [
|
||||
lswt
|
||||
swaybg
|
||||
wlr-randr
|
||||
];
|
||||
|
||||
# Common dotfiles
|
||||
home.file = {
|
||||
".config/nixpkgs/config.nix".text = ''
|
||||
{ allowUnfree = true; }
|
||||
'';
|
||||
".config/doom".source = ../dots/doom;
|
||||
"Pictures/Wallpapers".source = ../assets/Wallpapers;
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
@@ -1,101 +1,19 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
lib,
|
||||
window_manager,
|
||||
...
|
||||
}:
|
||||
let
|
||||
in
|
||||
|
||||
{
|
||||
imports = [
|
||||
# Core theming & integrations
|
||||
inputs.nix-colors.homeManagerModules.default
|
||||
inputs.stylix.homeModules.stylix
|
||||
inputs.nixcord.homeModules.nixcord
|
||||
# inputs.niri.homeModules.niri
|
||||
imports = [ ./common.nix ];
|
||||
|
||||
# Local modules
|
||||
./sessionVars.nix
|
||||
./stylix.nix
|
||||
./homePkgs.nix
|
||||
./services.nix
|
||||
|
||||
# Dots
|
||||
../dots/foot.nix
|
||||
../dots/zsh.nix
|
||||
../dots/xdg.nix
|
||||
../dots/hyprland.nix
|
||||
../dots/caelestia.nix
|
||||
];
|
||||
|
||||
# You can find color schemes at: https://github.com/tinted-theming/schemes
|
||||
# User-specific color scheme
|
||||
colorScheme = inputs.nix-colors.colorSchemes.hardcore;
|
||||
stylix.base16Scheme.base00 = "141414";
|
||||
|
||||
# Home Manager needs a bit of information about you and the paths it should manage.
|
||||
# User identity
|
||||
home.username = "game";
|
||||
home.homeDirectory = "/home/game";
|
||||
|
||||
# This determines compatibility with a specific Home Manager release.
|
||||
home.stateVersion = "23.11"; # Please read the comment before changing.
|
||||
|
||||
# Example GTK block (disabled)
|
||||
gtk = {
|
||||
enable = true;
|
||||
iconTheme = {
|
||||
name = "Reversal-black-dark";
|
||||
package = pkgs.reversal-icon-theme.override { allColorVariants = true; };
|
||||
};
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
############################
|
||||
# Wayland / Desktop tools
|
||||
############################
|
||||
lswt
|
||||
swaybg
|
||||
wlr-randr
|
||||
|
||||
############################
|
||||
# Experimental (inputs)
|
||||
############################
|
||||
# inputs.ladybird.packages."${pkgs.stdenv.hostPlatform.system}".ladybird
|
||||
|
||||
# ##########################
|
||||
# Examples (disabled)
|
||||
# ##########################
|
||||
# pkgs.hello
|
||||
# (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
|
||||
# (pkgs.writeShellScriptBin "my-hello" ''
|
||||
# echo "Hello, ${config.home.username}!"
|
||||
# '')
|
||||
];
|
||||
|
||||
# Dotfiles & static files managed by Home Manager
|
||||
home.file = {
|
||||
".config/nixpkgs/config.nix".text = ''
|
||||
{ allowUnfree = true; }
|
||||
'';
|
||||
".config/doom".source = ../dots/doom;
|
||||
# ".config/quickshell".source = ../dots/shell;
|
||||
# ".config/kitty".source = ../../universal/dots/kitty;
|
||||
# ".config/nvim".source = ../../universal/dots/nvim;
|
||||
"Pictures/Wallpapers".source = ../assets/Wallpapers;
|
||||
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# If you don't manage your shell with Home Manager, remember to source:
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
|
||||
# /etc/profiles/per-user/mrfluffy/etc/profile.d/hm-session-vars.sh
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ in
|
||||
profiles.default = {
|
||||
extensions = with pkgs.vscode-extensions; [
|
||||
platformio.platformio-vscode-ide
|
||||
ms-vscode.cpptools
|
||||
ms-vscode.cpptools
|
||||
];
|
||||
|
||||
# Optional: keep Code from trying to self-update
|
||||
@@ -125,20 +125,14 @@ in
|
||||
services.kdeconnect.enable = true;
|
||||
|
||||
home.packages = with pkgs; [
|
||||
############################
|
||||
# Shells & Terminals
|
||||
############################
|
||||
# ─── Shells & Terminals ──────────────────────────────────────────────────────
|
||||
alacritty
|
||||
zsh
|
||||
|
||||
############################
|
||||
# CLI Shit
|
||||
############################
|
||||
# ─── CLI Shit ────────────────────────────────────────────────────────────────
|
||||
atuin
|
||||
|
||||
############################
|
||||
# System Utilities
|
||||
############################
|
||||
# ─── System Utilities ──────────────────────────────────────────────────────────
|
||||
app2unit
|
||||
brightnessctl
|
||||
ddcutil
|
||||
@@ -150,15 +144,11 @@ in
|
||||
xarchiver
|
||||
xdg-user-dirs
|
||||
|
||||
############################
|
||||
# Monitoring & TUI Apps
|
||||
############################
|
||||
# ─── Monitoring & TUI Apps ───────────────────────────────────────────────────
|
||||
btop
|
||||
cava
|
||||
|
||||
############################
|
||||
# Wayland / Desktop Tools
|
||||
############################
|
||||
# ─── Wayland / Desktop Tools ─────────────────────────────────────────────────
|
||||
grim
|
||||
hyprpaper
|
||||
hyprpicker
|
||||
@@ -168,48 +158,35 @@ in
|
||||
swappy
|
||||
wf-recorder
|
||||
|
||||
############################
|
||||
# Audio / Media Tools
|
||||
############################
|
||||
# ─── Audio / Media Tools ─────────────────────────────────────────────────────
|
||||
openai-whisper
|
||||
pamixer
|
||||
playerctl
|
||||
alsa-utils
|
||||
|
||||
############################
|
||||
# Browsers & Web
|
||||
############################
|
||||
# ─── Browsers & Web ────────────────────────────────────────────────────────────
|
||||
brave
|
||||
firefox
|
||||
ladybird
|
||||
wgnord
|
||||
|
||||
############################
|
||||
# Communication & Sharing
|
||||
############################
|
||||
# ─── Communication & Sharing ─────────────────────────────────────────────────
|
||||
#element-desktop
|
||||
localsend
|
||||
thunderbird
|
||||
|
||||
############################
|
||||
# Documents & Viewers
|
||||
############################
|
||||
libreoffice
|
||||
# ─── Documents & Viewers ─────────────────────────────────────────────────────
|
||||
libreoffice-fresh
|
||||
zathura
|
||||
|
||||
############################
|
||||
# Media Players & Imaging
|
||||
############################
|
||||
# ─── Media Players & Imaging ─────────────────────────────────────────────────
|
||||
imv
|
||||
mpv
|
||||
#upscaler
|
||||
pear-desktop
|
||||
libsixel
|
||||
|
||||
############################
|
||||
# Development Toolchains
|
||||
############################
|
||||
# ─── Development Toolchains ──────────────────────────────────────────────────
|
||||
gdb
|
||||
nodejs_20
|
||||
platformio
|
||||
@@ -222,29 +199,21 @@ in
|
||||
#inputs.qs-qml.packages.${pkgs.stdenv.hostPlatform.system}.qml-ts-mode
|
||||
#inputs.qs-qml.packages.${pkgs.stdenv.hostPlatform.system}.tree-sitter-qmljs
|
||||
|
||||
############################
|
||||
# Game Dev / Engines / Creative
|
||||
############################
|
||||
# ─── Game Dev / Engines / Creative ──────────────────────────────────────────
|
||||
blender
|
||||
godot_4
|
||||
freecad
|
||||
|
||||
############################
|
||||
# Emulation
|
||||
############################
|
||||
# ─── Emulation ────────────────────────────────────────────────────────────────
|
||||
fuse
|
||||
fuse-emulator
|
||||
fuse3
|
||||
|
||||
############################
|
||||
# Android Tools
|
||||
############################
|
||||
# ─── Android Tools ───────────────────────────────────────────────────────────
|
||||
android-tools
|
||||
scrcpy
|
||||
|
||||
############################
|
||||
# Gaming & Launchers
|
||||
############################
|
||||
# ─── Gaming & Launchers ──────────────────────────────────────────────────────
|
||||
dualsensectl
|
||||
gamemode
|
||||
goverlay
|
||||
@@ -260,9 +229,7 @@ in
|
||||
|
||||
abaddon
|
||||
|
||||
############################
|
||||
# KDE / File Management
|
||||
############################
|
||||
# ─── KDE / File Management ───────────────────────────────────────────────────
|
||||
kdePackages.qt6ct
|
||||
kdePackages.baloo # new
|
||||
kdePackages.baloo-widgets # new
|
||||
@@ -285,15 +252,11 @@ in
|
||||
adw-gtk3
|
||||
pywalfox-native
|
||||
|
||||
############################
|
||||
# Experimental (inputs)
|
||||
############################
|
||||
# ─── Experimental (inputs) ───────────────────────────────────────────────────
|
||||
#inputs.ladybird.packages."${pkgs.stdenv.hostPlatform.system}".ladybird
|
||||
#inputs.hyprlauncher.packages.${pkgs.stdenv.hostPlatform.system}.default
|
||||
|
||||
############################
|
||||
# Blockchain (inputs)
|
||||
############################
|
||||
# ─── Blockchain (inputs) ─────────────────────────────────────────────────────
|
||||
#inputs.caelestia-cli.packages.${pkgs.stdenv.hostPlatform.system}.caelestia-cli
|
||||
#inputs.caelestia.packages.${pkgs.stdenv.hostPlatform.system}.caelestia-shell
|
||||
];
|
||||
|
||||
@@ -1,120 +1,27 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
lib,
|
||||
window_manager,
|
||||
...
|
||||
}:
|
||||
let
|
||||
in
|
||||
|
||||
{
|
||||
imports = [
|
||||
# Core theming & integrations
|
||||
inputs.nix-colors.homeManagerModules.default
|
||||
inputs.stylix.homeModules.stylix
|
||||
inputs.nixcord.homeModules.nixcord
|
||||
# inputs.niri.homeModules.niri
|
||||
imports = [ ./common.nix ];
|
||||
|
||||
# Local modules
|
||||
./sessionVars.nix
|
||||
./stylix.nix
|
||||
./homePkgs.nix
|
||||
./services.nix
|
||||
|
||||
# Dots
|
||||
../dots/foot.nix
|
||||
../dots/waybar.nix
|
||||
../dots/zsh.nix
|
||||
../dots/nixcord.nix
|
||||
#../dots/hyprlock.nix
|
||||
../dots/xdg.nix
|
||||
../dots/river.nix
|
||||
#../dots/niri.nix
|
||||
../dots/hyprland.nix
|
||||
../dots/hyprpaper.nix
|
||||
../dots/caelestia.nix
|
||||
../dots/dankMeterialShell.nix
|
||||
];
|
||||
|
||||
# You can find color schemes at: https://github.com/tinted-theming/schemes
|
||||
# User-specific color scheme
|
||||
colorScheme = inputs.nix-colors.colorSchemes.hardcore;
|
||||
stylix.base16Scheme.base00 = "141414";
|
||||
|
||||
# Home Manager needs a bit of information about you and the paths it should manage.
|
||||
# User identity
|
||||
home.username = "mrfluffy";
|
||||
home.homeDirectory = "/home/mrfluffy";
|
||||
|
||||
# This determines compatibility with a specific Home Manager release.
|
||||
home.stateVersion = "23.11"; # Please read the comment before changing.
|
||||
|
||||
# Example GTK block (disabled)
|
||||
gtk = {
|
||||
enable = true;
|
||||
gtk3 = {
|
||||
theme = {
|
||||
name = "adw-gtk3";
|
||||
package = pkgs.adw-gtk3;
|
||||
};
|
||||
};
|
||||
#gtk4 = {
|
||||
# theme = {
|
||||
# name = "adw-gtk3";
|
||||
# package = pkgs.adw-gtk3;
|
||||
# };
|
||||
#};
|
||||
iconTheme = {
|
||||
name = "Reversal-black-dark";
|
||||
package = pkgs.reversal-icon-theme.override { allColorVariants = true; };
|
||||
# User-specific GTK theme
|
||||
gtk.gtk3 = {
|
||||
theme = {
|
||||
name = "adw-gtk3";
|
||||
package = pkgs.adw-gtk3;
|
||||
};
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
############################
|
||||
# Wayland / Desktop tools
|
||||
############################
|
||||
lswt
|
||||
swaybg
|
||||
wlr-randr
|
||||
|
||||
############################
|
||||
# Experimental (inputs)
|
||||
############################
|
||||
# inputs.ladybird.packages."${pkgs.stdenv.hostPlatform.system}".ladybird
|
||||
|
||||
# ##########################
|
||||
# Examples (disabled)
|
||||
# ##########################
|
||||
# pkgs.hello
|
||||
# (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
|
||||
# (pkgs.writeShellScriptBin "my-hello" ''
|
||||
# echo "Hello, ${config.home.username}!"
|
||||
# '')
|
||||
];
|
||||
|
||||
# Dotfiles & static files managed by Home Manager
|
||||
home.file = {
|
||||
".config/nixpkgs/config.nix".text = ''
|
||||
{ allowUnfree = true; }
|
||||
'';
|
||||
".config/doom".source = ../dots/doom;
|
||||
# ".config/quickshell".source = ../dots/shell;
|
||||
# ".config/kitty".source = ../../universal/dots/kitty;
|
||||
# ".config/nvim".source = ../../universal/dots/nvim;
|
||||
"Pictures/Wallpapers".source = ../assets/Wallpapers;
|
||||
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# If you don't manage your shell with Home Manager, remember to source:
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
|
||||
# /etc/profiles/per-user/mrfluffy/etc/profile.d/hm-session-vars.sh
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
|
||||
@@ -6,27 +6,7 @@
|
||||
window_manager,
|
||||
...
|
||||
}:
|
||||
let
|
||||
#quickshellPackage = inputs.caelestia.packages.${pkgs.stdenv.hostPlatform.system}.caelestia-shell;
|
||||
in
|
||||
|
||||
{
|
||||
#systemd.user.services.quickshell = lib.mkIf (window_manager == "hyprland") {
|
||||
# Unit = {
|
||||
# Description = "QuickShell Application";
|
||||
# After = [ "graphical-session.target" ];
|
||||
# Requires = [ "graphical-session.target" ];
|
||||
# };
|
||||
|
||||
# Service = {
|
||||
# Type = "simple";
|
||||
# ExecStart = "${quickshellPackage}/bin/caelestia-shell";
|
||||
# ExecStartPre = "/bin/sh -c 'test -n \"$WAYLAND_DISPLAY\"'";
|
||||
# Restart = "always";
|
||||
# RestartSec = "5s";
|
||||
# };
|
||||
|
||||
# Install = {
|
||||
# WantedBy = [ "graphical-session.target" ];
|
||||
# };
|
||||
#};
|
||||
# User services can be added here
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
WLR_DRM_NO_ATOMIC = 1;
|
||||
VDPAU_DRIVER = "radeonsi";
|
||||
LIBVA_DRIVER_NAME = "radeonsi";
|
||||
OLLAMA_HOST = "0.0.0.0";
|
||||
OLLAMA_HOST = "127.0.0.1";
|
||||
PATH = "$HOME/.config/emacs/bin:$PATH";
|
||||
FZF_DEFAULT_COMMAND = "${lib.getExe pkgs.ripgrep} ~ --files --hidden";
|
||||
FZF_DEFAULT_OPTS = "--height 30% --reverse";
|
||||
@@ -29,7 +29,7 @@
|
||||
GNUPGHOME = "$XDG_DATA_HOME/gnupg";
|
||||
GOPATH = "$XDG_DATA_HOME/go";
|
||||
GRADLE_USER_HOME = "$XDG_DATA_HOME/gradle";
|
||||
IPYTHONDIR = "$XDG_CONFIG_HOMEipython";
|
||||
IPYTHONDIR = "$XDG_CONFIG_HOME/ipython";
|
||||
JUPYTER_CONFIG_DIR = "$XDG_CONFIG_HOME/jupyter";
|
||||
LESSHISTFILE = "$XDG_CACHE_HOME/less/history";
|
||||
NUGET_PACKAGES = "$XDG_CACHE_HOME/NuGetPackages";
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
@@ -50,7 +50,7 @@ in
|
||||
# enable = true;
|
||||
# #package = lib.mkForce (pkgs.reversal-icon-theme.override { allColorVariants = true; });
|
||||
# light = "Reversal-black";
|
||||
# dark = "Reversal-black-dark";
|
||||
# dark = "Reversal-black-dark";
|
||||
#};
|
||||
|
||||
polarity = "dark";
|
||||
@@ -80,9 +80,9 @@ in
|
||||
};
|
||||
sizes = {
|
||||
applications = 12;
|
||||
desktop = 12;
|
||||
popups = 14;
|
||||
terminal = 16;
|
||||
desktop = 12;
|
||||
popups = 14;
|
||||
terminal = 16;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
105
home/work.nix
105
home/work.nix
@@ -1,114 +1,19 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
lib,
|
||||
window_manager,
|
||||
...
|
||||
}:
|
||||
let
|
||||
in
|
||||
|
||||
{
|
||||
imports = [
|
||||
# Core theming & apps
|
||||
inputs.nix-colors.homeManagerModules.default
|
||||
inputs.stylix.homeModules.stylix
|
||||
inputs.nixcord.homeModules.nixcord
|
||||
# inputs.niri.homeModules.niri
|
||||
imports = [ ./common.nix ];
|
||||
|
||||
# Local modules
|
||||
./sessionVars.nix
|
||||
./stylix.nix
|
||||
./homePkgs.nix
|
||||
./services.nix
|
||||
|
||||
# Dots
|
||||
../dots/foot.nix
|
||||
../dots/waybar.nix
|
||||
../dots/zsh.nix
|
||||
../dots/nixcord.nix
|
||||
#../dots/hyprlock.nix
|
||||
../dots/xdg.nix
|
||||
../dots/river.nix
|
||||
#../dots/niri.nix
|
||||
../dots/hyprland.nix
|
||||
../dots/hyprpaper.nix
|
||||
../dots/caelestia.nix
|
||||
../dots/dankMeterialShell.nix
|
||||
|
||||
];
|
||||
|
||||
# You can find color schemes at: https://github.com/tinted-theming/schemes
|
||||
# User-specific color scheme (different from mrfluffy)
|
||||
colorScheme = inputs.nix-colors.colorSchemes.blueish;
|
||||
stylix.base16Scheme.base00 = "0F1417";
|
||||
|
||||
# Home Manager user information
|
||||
# User identity
|
||||
home.username = "work";
|
||||
home.homeDirectory = "/home/work";
|
||||
|
||||
# This determines compatibility with a specific Home Manager release.
|
||||
home.stateVersion = "23.11"; # Please read the comment before changing.
|
||||
|
||||
# Example GTK block (disabled)
|
||||
gtk = {
|
||||
enable = true;
|
||||
iconTheme = {
|
||||
name = "Reversal-black-dark";
|
||||
package = pkgs.reversal-icon-theme.override { allColorVariants = true; };
|
||||
};
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
############################
|
||||
# Wayland / Desktop tools
|
||||
############################
|
||||
lswt
|
||||
swaybg
|
||||
wlr-randr
|
||||
|
||||
############################
|
||||
# Browsers
|
||||
############################
|
||||
|
||||
############################
|
||||
# work stuff
|
||||
############################
|
||||
#awscli2
|
||||
|
||||
|
||||
# swaynotificationcenter
|
||||
# inputs.ladybird.packages."${pkgs.stdenv.hostPlatform.system}".ladybird
|
||||
|
||||
# pkgs.hello
|
||||
# (pkgs.nerdfonts.override { fonts = [ "FantasqueSansMono" ]; })
|
||||
# (pkgs.writeShellScriptBin "my-hello" ''
|
||||
# echo "Hello, ${config.home.username}!"
|
||||
# '')
|
||||
];
|
||||
|
||||
# Dotfiles & static files managed by Home Manager
|
||||
home.file = {
|
||||
".config/nixpkgs/config.nix".text = ''
|
||||
{ allowUnfree = true; }
|
||||
'';
|
||||
".config/doom".source = ../dots/doom;
|
||||
# ".config/quickshell".source = ../dots/shell;
|
||||
# ".config/kitty".source = ../../universal/dots/kitty;
|
||||
# ".config/nvim".source = ../../universal/dots/nvim;
|
||||
"Pictures/Wallpapers".source = ../assets/Wallpapers;
|
||||
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# If you don't manage your shell with Home Manager, remember to source:
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
|
||||
# /etc/profiles/per-user/mrfluffy/etc/profile.d/hm-session-vars.sh
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
|
||||
@@ -25,9 +25,9 @@ in
|
||||
loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
extraInstallCommands = ''
|
||||
${lib.getExe pkgs.gnused} -i 's/default .*/default *-specialisation-00-main-system.conf/' /boot/loader/loader.conf
|
||||
'';
|
||||
extraInstallCommands = ''
|
||||
${lib.getExe pkgs.gnused} -i 's/default .*/default *-specialisation-00-main-system.conf/' /boot/loader/loader.conf
|
||||
'';
|
||||
#sortKey = "z-normal";
|
||||
};
|
||||
efi.canTouchEfiVariables = true;
|
||||
|
||||
@@ -7,6 +7,9 @@
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
|
||||
# Shared VA-API / VDPAU bits across both machines
|
||||
commonVA = with pkgs; [
|
||||
libva
|
||||
@@ -18,7 +21,7 @@ in
|
||||
# ── Graphics ─────────────────────────────────────────────────────────────────
|
||||
hardware.graphics = lib.mkMerge [
|
||||
# Laptop: Intel stack
|
||||
(lib.mkIf (systemName == "laptop") {
|
||||
(lib.mkIf isLaptop {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
extraPackages = with pkgs; [
|
||||
@@ -29,7 +32,7 @@ in
|
||||
})
|
||||
|
||||
# PC: AMD/ROCm stack
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
(lib.mkIf isPc {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
extraPackages = with pkgs; [
|
||||
|
||||
@@ -1,18 +1,35 @@
|
||||
{ config, lib, pkgs, systemName, ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
systemName,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
# Set console keymap based on systemName
|
||||
console.keyMap = if systemName == "laptop" then "ie" else "us";
|
||||
console.keyMap =
|
||||
if isLaptop
|
||||
then "ie"
|
||||
else "us";
|
||||
|
||||
# Locale settings
|
||||
i18n.defaultLocale =
|
||||
if systemName == "laptop"
|
||||
if isLaptop
|
||||
then "en_IE.UTF-8"
|
||||
else "en_US.UTF-8";
|
||||
|
||||
i18n.extraLocaleSettings = let
|
||||
locale = if systemName == "laptop" then "en_IE.UTF-8" else "en_US.UTF-8";
|
||||
in {
|
||||
i18n.extraLocaleSettings =
|
||||
let
|
||||
locale =
|
||||
if isLaptop
|
||||
then "en_IE.UTF-8"
|
||||
else "en_US.UTF-8";
|
||||
in {
|
||||
LC_ADDRESS = locale;
|
||||
LC_IDENTIFICATION = locale;
|
||||
LC_MEASUREMENT = locale;
|
||||
|
||||
@@ -7,13 +7,13 @@
|
||||
}:
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
networking = lib.mkMerge [
|
||||
# Hostname per system type
|
||||
(lib.mkIf isLaptop { hostName = "mrfluffyLaptop"; })
|
||||
(lib.mkIf isPc { hostName = "mrfluffyPC"; })
|
||||
(lib.mkIf isPc { hostName = "mrfluffyPC"; })
|
||||
|
||||
# Common networking config
|
||||
{
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
inputs,
|
||||
pkgs,
|
||||
inputs,
|
||||
pkgs-stable,
|
||||
...
|
||||
}:
|
||||
@@ -29,8 +29,8 @@ let
|
||||
-- HQ shader map
|
||||
local shader_map = {
|
||||
[1080] = "${anime4k}/Anime4K_Clamp_Highlights.glsl:${anime4k}/Anime4K_Restore_CNN_VL.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_VL.glsl:${anime4k}/Anime4K_AutoDownscalePre_x2.glsl:${anime4k}/Anime4K_AutoDownscalePre_x4.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_M.glsl",
|
||||
[720] = "${anime4k}/Anime4K_Clamp_Highlights.glsl:${anime4k}/Anime4K_Restore_CNN_Soft_VL.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_VL.glsl:${anime4k}/Anime4K_AutoDownscalePre_x2.glsl:${anime4k}/Anime4K_AutoDownscalePre_x4.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_M.glsl",
|
||||
[480] = "${anime4k}/Anime4K_Clamp_Highlights.glsl:${anime4k}/Anime4K_Upscale_Denoise_CNN_x2_VL.glsl:${anime4k}/Anime4K_AutoDownscalePre_x2.glsl:${anime4k}/Anime4K_AutoDownscalePre_x4.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_M.glsl"
|
||||
[720] = "${anime4k}/Anime4K_Clamp_Highlights.glsl:${anime4k}/Anime4K_Restore_CNN_Soft_VL.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_VL.glsl:${anime4k}/Anime4K_AutoDownscalePre_x2.glsl:${anime4k}/Anime4K_AutoDownscalePre_x4.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_M.glsl",
|
||||
[480] = "${anime4k}/Anime4K_Clamp_Highlights.glsl:${anime4k}/Anime4K_Upscale_Denoise_CNN_x2_VL.glsl:${anime4k}/Anime4K_AutoDownscalePre_x2.glsl:${anime4k}/Anime4K_AutoDownscalePre_x4.glsl:${anime4k}/Anime4K_Upscale_CNN_x2_M.glsl"
|
||||
}
|
||||
|
||||
local resolutions = { 1080, 720, 480 }
|
||||
|
||||
@@ -6,10 +6,12 @@
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
in
|
||||
{
|
||||
###############################################
|
||||
# Desktop & Input
|
||||
###############################################
|
||||
# ─── Desktop & Input ───────────────────────────────────────────────────────
|
||||
services.xserver.windowManager.fvwm2.gestures = true;
|
||||
|
||||
# Enable touchpad support (enabled by default in most desktop managers).
|
||||
@@ -31,49 +33,26 @@
|
||||
# services.xserver.displayManager.gdm.enable = true;
|
||||
# services.xserver.desktopManager.gnome.enable = true;
|
||||
|
||||
###############################################
|
||||
# Audio / Bluetooth
|
||||
###############################################
|
||||
services.pipewire = lib.mkMerge [
|
||||
(lib.mkIf (systemName == "laptop") {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
extraConfig.pipewire = {
|
||||
"92-low-latency" = {
|
||||
"context.properties" = {
|
||||
"default.clock.rate" = 48000;
|
||||
"default.clock.allowed-rates" = [ 48000 ];
|
||||
};
|
||||
};
|
||||
# ─── Audio / Bluetooth ──────────────────────────────────────────────────────
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
extraConfig.pipewire."92-low-latency"."context.properties" =
|
||||
if isLaptop
|
||||
then {
|
||||
"default.clock.rate" = 48000;
|
||||
"default.clock.allowed-rates" = [ 48000 ];
|
||||
}
|
||||
else {
|
||||
"default.clock.rate" = 96000;
|
||||
"default.clock.allowed-rates" = [ 44100 48000 96000 ];
|
||||
};
|
||||
})
|
||||
(lib.mkIf (systemName == "pc") {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
extraConfig.pipewire = {
|
||||
"92-low-latency" = {
|
||||
"context.properties" = {
|
||||
"default.clock.rate" = 96000;
|
||||
"default.clock.allowed-rates" = [
|
||||
44100
|
||||
48000
|
||||
96000
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
})
|
||||
];
|
||||
};
|
||||
|
||||
###############################################
|
||||
# nice shit
|
||||
###############################################
|
||||
# ─── Nice Shit ──────────────────────────────────────────────────────────────
|
||||
services.ananicy = {
|
||||
enable = true;
|
||||
package = pkgs.ananicy-cpp;
|
||||
@@ -88,18 +67,14 @@
|
||||
|
||||
services.blueman.enable = true;
|
||||
|
||||
###############################################
|
||||
# Printing & Files
|
||||
###############################################
|
||||
# ─── Printing & Files ───────────────────────────────────────────────────────
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
services.gvfs.enable = true;
|
||||
services.tumbler.enable = true;
|
||||
|
||||
###############################################
|
||||
# Time & Power
|
||||
###############################################
|
||||
# ─── Time & Power ───────────────────────────────────────────────────────────
|
||||
services.automatic-timezoned.enable = true;
|
||||
|
||||
# Power management
|
||||
@@ -109,20 +84,18 @@
|
||||
};
|
||||
|
||||
# Laptop-specific lid and sleep behavior
|
||||
services.logind.settings.Login = lib.mkIf (systemName == "laptop") {
|
||||
services.logind.settings.Login = lib.mkIf isLaptop {
|
||||
HandleLidSwitch = "suspend-then-hibernate";
|
||||
HandleLidSwitchExternalPower = "suspend-then-hibernate";
|
||||
HandleLidSwitchDocked = "suspend-then-hibernate";
|
||||
};
|
||||
|
||||
systemd.sleep.extraConfig = lib.mkIf (systemName == "laptop") ''
|
||||
systemd.sleep.extraConfig = lib.mkIf isLaptop ''
|
||||
HibernateDelaySec=120min
|
||||
SuspendState=mem
|
||||
'';
|
||||
|
||||
###############################################
|
||||
# Developer Tools & Services
|
||||
###############################################
|
||||
# ─── Developer Tools & Services ─────────────────────────────────────────────
|
||||
# direnv speedup
|
||||
services.lorri.enable = true;
|
||||
|
||||
@@ -135,7 +108,7 @@
|
||||
#services.flatpak.enable = true;
|
||||
|
||||
# Sunshine (only on PC)
|
||||
services.sunshine = lib.mkIf (systemName == "pc") {
|
||||
services.sunshine = lib.mkIf isPc {
|
||||
enable = false;
|
||||
settings = {
|
||||
sunshine_name = "nixos";
|
||||
@@ -168,11 +141,11 @@
|
||||
};
|
||||
|
||||
# Ollama (only on PC)
|
||||
services.ollama = lib.mkIf (systemName == "pc") {
|
||||
services.ollama = lib.mkIf isPc {
|
||||
enable = true;
|
||||
package = pkgs.ollama-rocm;
|
||||
port = 11434;
|
||||
host = "0.0.0.0";
|
||||
host = "127.0.0.1"; # Bind to localhost only for security
|
||||
rocmOverrideGfx = "11.0.0";
|
||||
environmentVariables = {
|
||||
OLLAMA_DEBUG = "1";
|
||||
@@ -180,14 +153,11 @@
|
||||
OLLAMA_NUM_CTX = "40000";
|
||||
OLLAMA_NUM_GPU = "20";
|
||||
OLLAMA_FLASH_ATTENTION = "true";
|
||||
# HSA_OVERRIDE_GFX_VERSION = "11.0.0";
|
||||
OLLAMA_KV_CACHE_TYPE = "f16";
|
||||
};
|
||||
};
|
||||
|
||||
###############################################
|
||||
# Systemd User Services
|
||||
###############################################
|
||||
# ─── Systemd User Services ──────────────────────────────────────────────────
|
||||
systemd.user.services.steam-run-url-service = {
|
||||
description = "Service to launch Steam URLs via FIFO";
|
||||
wantedBy = [ "default.target" ];
|
||||
@@ -217,9 +187,7 @@
|
||||
path = [ pkgs.steam ];
|
||||
};
|
||||
|
||||
###############################################
|
||||
# Networking & Remote
|
||||
###############################################
|
||||
# ─── Networking & Remote ────────────────────────────────────────────────────
|
||||
# services.resolved = {
|
||||
# enable = true;
|
||||
# dnssec = "true";
|
||||
@@ -231,14 +199,10 @@
|
||||
# Enable the OpenSSH daemon.
|
||||
services.openssh.enable = true;
|
||||
|
||||
###############################################
|
||||
# Virtualization
|
||||
###############################################
|
||||
# ─── Virtualization ─────────────────────────────────────────────────────────
|
||||
virtualisation.libvirtd.enable = true;
|
||||
|
||||
###############################################
|
||||
# Udev Rules
|
||||
###############################################
|
||||
# ─── Udev Rules ─────────────────────────────────────────────────────────────
|
||||
services.udev.packages = [
|
||||
pkgs.platformio-core
|
||||
pkgs.platformio
|
||||
|
||||
@@ -9,6 +9,9 @@
|
||||
}:
|
||||
|
||||
let
|
||||
isLaptop = systemName == "laptop";
|
||||
isPc = systemName == "pc";
|
||||
|
||||
oreo = pkgs.callPackage ./personalPKGS/oreo.nix { };
|
||||
|
||||
# Window manager toggles
|
||||
@@ -36,9 +39,7 @@ in
|
||||
#};
|
||||
#services.displayManager.cosmic-greeter.enable = true;
|
||||
|
||||
##############################################################################
|
||||
# Desktop / WM
|
||||
##############################################################################
|
||||
# ─── Desktop / WM ───────────────────────────────────────────────────────────
|
||||
programs.river-classic.enable = useRiver;
|
||||
|
||||
qt = {
|
||||
@@ -89,9 +90,7 @@ in
|
||||
# };
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Security / PolicyKit / PAM
|
||||
##############################################################################
|
||||
# ─── Security / PolicyKit / PAM ─────────────────────────────────────────────
|
||||
security = {
|
||||
rtkit.enable = true;
|
||||
polkit.enable = true;
|
||||
@@ -102,13 +101,11 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
##############################################################################
|
||||
# Virtualisation
|
||||
##############################################################################
|
||||
# ─── Virtualisation ─────────────────────────────────────────────────────────
|
||||
virtualisation = {
|
||||
docker = {
|
||||
enable = true;
|
||||
storageDriver = lib.mkIf (systemName == "pc") "btrfs";
|
||||
storageDriver = lib.mkIf isPc "btrfs";
|
||||
};
|
||||
libvirtd.enable = true;
|
||||
};
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user