progress...

This commit is contained in:
2026-02-13 19:21:27 +00:00
parent 540359308e
commit 58c8146cc0
16 changed files with 363 additions and 96 deletions

View File

@@ -0,0 +1,33 @@
{
den,
modules,
__findFile,
...
}:
{
den.aspects.laptop = {
nixos =
{
pkgs,
lib,
config,
...
}:
{
boot.initrd.availableKernelModules = [
"xhci_pci"
"thunderbolt"
"vmd"
"nvme"
];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
};
};
}

View File

@@ -9,17 +9,20 @@
includes = [ includes = [
<den/primary-user> <den/primary-user>
den.aspects.doloro-shared den.aspects.doloro-shared
modules.user.doloro
modules.hyprland modules.hyprland
<modules/hyprland/doloro-settings> <modules/hyprland/doloro-settings>
modules.sops modules.sops
modules.fish modules.fish
<modules/zen-browser>
modules.kitty
]; ];
nixos = nixos =
{ config, pkgs, ... }: { config, pkgs, ... }:
{ {
users.users.doloro = { users.users.doloro = {
isNormalUser = true;
shell = pkgs.fish; shell = pkgs.fish;
initialPassword = "sex";
hashedPasswordFile = config.sops.secrets."doloro-hashed_password".path; hashedPasswordFile = config.sops.secrets."doloro-hashed_password".path;
}; };
}; };

View File

@@ -8,6 +8,7 @@
den.aspects.laptop = { den.aspects.laptop = {
includes = [ includes = [
modules.nix modules.nix
modules.tuigreet
]; ];
nixos = nixos =
{ pkgs, config, ... }: { pkgs, config, ... }:
@@ -49,7 +50,7 @@
services.gnome.gnome-keyring.enable = true; services.gnome.gnome-keyring.enable = true;
hardware = { hardware = {
firmware = [ pkgs.intel-npu-driver ]; # firmware = [ pkgs.intel-npu-driver ];
cpu.intel = { cpu.intel = {
# npu.enable = true; # npu.enable = true;
}; };
@@ -97,8 +98,8 @@
boot.binfmt.emulatedSystems = [ "aarch64-linux" ]; boot.binfmt.emulatedSystems = [ "aarch64-linux" ];
# Define a user account. Don't forget to set a password with passwd. # Define a user account. Don't forget to set a password with passwd.
# users.users.doloro = { # users.users.doloro = {
# isNormalUser = true; # isNormalUser = true;
# shell = pkgs.fish; # shell = pkgs.fish;
# extraGroups = [ "wheel" ]; # Enable sudo for the user. # extraGroups = [ "wheel" ]; # Enable sudo for the user.
# packages = with pkgs; [ # packages = with pkgs; [
# tree # tree
@@ -109,6 +110,9 @@
# ]; # ];
# # initialPassword = "sex"; # # initialPassword = "sex";
# }; # };
users.users.root = {
password = "meowmeowmeow";
};
users.mutableUsers = false; users.mutableUsers = false;
services.system76-scheduler.enable = true; services.system76-scheduler.enable = true;

View File

@@ -1,15 +1,26 @@
{ den, modules, ... }: {
den,
modules,
__findFile,
...
}:
{ {
den.aspects.doloro-shared = { den.aspects.doloro-shared = {
includes = [ includes = [
modules.nixvim modules.nixvim
modules.nix modules.nix
modules.tmux
<modules/git/doloro>
]; ];
homeManager = { homeManager =
home = { { pkgs, ... }:
username = "doloro"; {
homeDirectory = "/home/doloro"; home = {
username = "doloro";
homeDirectory = "/home/doloro";
packages = with pkgs; [ wl-clipboard ];
};
programs.home-manager.enable = true;
}; };
};
}; };
} }

View File

@@ -1,24 +1,24 @@
{ den, __findFile, ... }: { den, __findFile, ... }:
{ {
# Homes # Homes
den.homes.x86_64-linux.doloro-desktop = { # den.homes.x86_64-linux.doloro-desktop = {
userName = "doloro";
};
# TODO
# den.homes.x86_64-linux.doloro-laptop = {
# userName = "doloro"; # userName = "doloro";
# }; # };
# Machines
den.hosts.x86_64-linux.desktop = {
users.doloro = {
includes = [ <modules/user/groups> ];
aspect = "doloro-desktop";
};
};
# TODO # TODO
# den.hosts.x86_64-linux.laptop = { den.homes.x86_64-linux.doloro-laptop = {
userName = "doloro";
};
# Machines
# den.hosts.x86_64-linux.desktop = {
# users.doloro = { # users.doloro = {
# aspect = "doloro-laptop"; # includes = [ <modules/user/groups> ];
# aspect = "doloro-desktop";
# }; # };
# }; # };
# TODO
den.hosts.x86_64-linux.laptop = {
users.doloro = {
aspect = "doloro-laptop";
};
};
} }

View File

@@ -1,44 +1,50 @@
{ modules, pkgs, ... }: { modules, ... }:
{ {
modules.fish = { modules.fish = {
nixos = { nixos = {
programs.fish.enable = true; programs.fish.enable = true;
}; };
homeManager = { homeManager =
home.shell.enableFishIntegration = true; { pkgs, ... }:
home.packages = [ pkgs.nix-output-monitor ]; {
programs = { home.shell.enableFishIntegration = true;
fish = { home.packages = [ pkgs.nix-output-monitor ];
enable = true; programs = {
shellInit = '' fish = {
set -g theme_nerd_fonts yes enable = true;
set -g theme_color_scheme nord shellInit = ''
set -g theme_display_user yes set -g theme_nerd_fonts yes
set -g fish_color_autosuggestion 6F6578 set -g theme_color_scheme nord
alias nik 'nix' set -g theme_display_user yes
''; set -g fish_color_autosuggestion 6F6578
# alias nos 'sudo echo; sudo nixos-rebuild switch --flake .#${aspect-name} --log-format internal-json -v &| nom --json' alias nik 'nix'
# alias hms 'home-manager switch --flake .#${aspect-name} --log-format internal-json -v &| nom --json' '';
plugins = [ # alias nos 'sudo echo; sudo nixos-rebuild switch --flake .#${aspect-name} --log-format internal-json -v &| nom --json'
{ # alias hms 'home-manager switch --flake .#${aspect-name} --log-format internal-json -v &| nom --json'
name = "bobthefish"; plugins = [
src = pkgs.fetchFromGitHub { {
owner = "oh-my-fish"; name = "bobthefish";
repo = "theme-bobthefish"; src = pkgs.fetchFromGitHub {
rev = "e3b4d4eafc23516e35f162686f08a42edf844e40"; owner = "oh-my-fish";
sha256 = "sha256-cXOYvdn74H4rkMWSC7G6bT4wa9d3/3vRnKed2ixRnuA="; repo = "theme-bobthefish";
}; rev = "e3b4d4eafc23516e35f162686f08a42edf844e40";
} sha256 = "sha256-cXOYvdn74H4rkMWSC7G6bT4wa9d3/3vRnKed2ixRnuA=";
]; };
}; }
eza = { ];
enable = true; };
enableFishIntegration = true; eza = {
icons = "auto"; enable = true;
git = true; enableFishIntegration = true;
extraOptions = [ ]; icons = "auto";
git = true;
extraOptions = [ ];
};
direnv = {
enable = true;
nix-direnv.enable = true;
};
}; };
}; };
};
}; };
} }

45
config/modules/git.nix Normal file
View File

@@ -0,0 +1,45 @@
{ den, modules, ... }:
{
modules.git = {
provides = {
doloro = {
homeManager =
{ home, pkgs, ... }:
{
programs.git = {
enable = true;
settings = {
user = {
name = "Doloro1978";
email = "doloroo@proton.me";
signingKey = "089B373588540877";
};
commit = {
gpgSign = true;
};
pull = {
rebase = true;
};
};
};
programs.gpg = {
enable = true;
};
services = {
gpg-agent = {
enable = true;
pinentry = {
package = pkgs.pinentry-qt;
program = "pinentry-qt";
};
};
};
};
nixos =
{ pkgs, ... }:
{
};
};
};
};
}

View File

@@ -101,6 +101,7 @@
"$mainMod, C, killactive" "$mainMod, C, killactive"
"$mainMod, M, exec, uwsm stop" "$mainMod, M, exec, uwsm stop"
"$mainMod, E, exec, $fileManager" "$mainMod, E, exec, $fileManager"
"$mainMod, Q, exec, kitty"
"$mainMod, V, togglefloating," "$mainMod, V, togglefloating,"
"$mainMod, P, pseudo, # dwindle" "$mainMod, P, pseudo, # dwindle"
"$mainMod, J, togglesplit, # dwindle" "$mainMod, J, togglesplit, # dwindle"

View File

@@ -11,6 +11,12 @@
nixos = nixos =
{ pkgs, ... }: { pkgs, ... }:
{ {
environment.systemPackages = with pkgs; [
wayfreeze
grim
slurp
wlogout
];
programs.xwayland.enable = true; programs.xwayland.enable = true;
programs.hyprland = { programs.hyprland = {
enable = true; enable = true;

19
config/modules/kitty.nix Normal file
View File

@@ -0,0 +1,19 @@
{ den, modules, ... }:
{
modules.kitty = {
homeManager = {
programs.kitty = {
enable = true;
font = {
name = "Google Sans Code Nerd Font";
size = 11;
};
settings = {
sync_to_monitor = "yes";
background_opacity = 0.6;
cursor_trail = 1;
};
};
};
};
}

View File

@@ -8,31 +8,35 @@
}; };
}; };
modules.sops = { modules.sops = {
homeManager = { homeManager =
imports = [ { ... }:
inputs.sops-nix.homeManagerModules.sops {
]; imports = [
sops = { inputs.sops-nix.homeManagerModules.sops
age.keyFile = "/home/doloro/.config/sops/age/key.txt"; # must have no password! ];
defaultSopsFile = ./secrets.yaml; sops = {
age.keyFile = "/home/doloro/.config/sops/age/key.txt"; # must have no password!
defaultSopsFile = ./secrets.yaml;
};
}; };
}; nixos =
nixos = { { ... }:
imports = [ {
inputs.sops-nix.nixosModules.sops imports = [
]; inputs.sops-nix.nixosModules.sops
sops = { ];
age.keyFile = "/etc/ssh/ssh_host_ed25519_key"; sops = {
defaultSopsFile = ./secrets.yaml; # age.keyFile = "/etc/ssh/ssh_host_ed25519_key";
secrets = { defaultSopsFile = ./secrets.yaml;
root-hashed_password = { secrets = {
neededForUsers = true; root-hashed_password = {
}; neededForUsers = true;
doloro-hashed_password = { };
neededForUsers = true; doloro-hashed_password = {
neededForUsers = true;
};
}; };
}; };
}; };
};
}; };
} }

View File

@@ -1,18 +1,22 @@
{ pkgs, modules, ... }: { modules, ... }:
{ {
modules.tmux = { modules.tmux = {
programs.tmux = { homeManager =
enable = true; { home, pkgs, ... }:
plugins = with pkgs.tmuxPlugins; [ {
sensible programs.tmux = {
minimal-tmux-status enable = true;
]; plugins = with pkgs.tmuxPlugins; [
extraConfig = '' sensible
set-option -g default-terminal "xterm-256color" minimal-tmux-status
set -a terminal-features "xterm-256color:RGB" ];
set -g status-bg black extraConfig = ''
set -g status-fg white set-option -g default-terminal "xterm-256color"
''; set -a terminal-features "xterm-256color:RGB"
}; set -g status-bg black
set -g status-fg white
'';
};
};
}; };
} }

View File

@@ -0,0 +1,18 @@
{ den, modules, ... }:
{
modules.tuigreet = {
nixos =
{ pkgs, config, ... }:
{
services.greetd = {
enable = true;
settings = {
default_session = {
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --sessions ${config.services.xserver.displayManager.sessionData.desktops}/share/xsessions:${config.services.xserver.displayManager.sessionData.desktops}/share/wayland-sessions --remember --remember-user-session";
user = "greeter";
};
};
};
};
};
}

View File

@@ -0,0 +1,88 @@
{
den,
modules,
inputs,
...
}:
{
flake-file.inputs = {
zen-browser.url = "github:youwen5/zen-browser-flake";
zen-browser.inputs.nixpkgs.follows = "nixpkgs";
};
modules.zen-browser = {
homeManager =
{
home,
pkgs,
lib,
...
}:
let
extension = shortId: guid: {
name = guid;
value = {
install_url = "https://addons.mozilla.org/en-US/firefox/downloads/latest/${shortId}/latest.xpi";
installation_mode = "normal_installed";
};
};
prefs = {
# Check these out at about:config
"extensions.autoDisableScopes" = 0;
"extensions.pocket.enabled" = false;
# ...
};
extensions = [
# To add additional extensions, find it on addons.mozilla.org, find
# the short ID in the url (like https://addons.mozilla.org/en-US/firefox/addon/!SHORT_ID!/)
# Then go to https://addons.mozilla.org/api/v5/addons/addon/!SHORT_ID!/ to get the guid
(extension "ublock-origin" "uBlock0@raymondhill.net")
# ...
];
in
{
home.packages = [
(pkgs.wrapFirefox
inputs.zen-browser.packages.${pkgs.stdenv.hostPlatform.system}.zen-browser-unwrapped
{
extraPrefs = lib.concatLines (
lib.mapAttrsToList (
name: value: "lockPref(${lib.strings.toJSON name}, ${lib.strings.toJSON value});"
) prefs
);
extraPolicies = {
DisableTelemetry = true;
ExtensionSettings = builtins.listToAttrs extensions;
SearchEngines = {
Default = "ddg";
Add = [
{
Name = "nixpkgs packages";
URLTemplate = "https://search.nixos.org/packages?query={searchTerms}";
IconURL = "https://wiki.nixos.org/favicon.ico";
Alias = "@np";
}
{
Name = "NixOS options";
URLTemplate = "https://search.nixos.org/options?query={searchTerms}";
IconURL = "https://wiki.nixos.org/favicon.ico";
Alias = "@no";
}
{
Name = "NixOS Wiki";
URLTemplate = "https://wiki.nixos.org/w/index.php?search={searchTerms}";
IconURL = "https://wiki.nixos.org/favicon.ico";
Alias = "@nw";
}
];
};
};
}
)
];
};
};
}

23
flake.lock generated
View File

@@ -716,7 +716,8 @@
"nixvim": "nixvim", "nixvim": "nixvim",
"raspberry-pi-nix": "raspberry-pi-nix", "raspberry-pi-nix": "raspberry-pi-nix",
"sops-nix": "sops-nix", "sops-nix": "sops-nix",
"systems": "systems_3" "systems": "systems_3",
"zen-browser": "zen-browser"
} }
}, },
"rpi-bluez-firmware-src": { "rpi-bluez-firmware-src": {
@@ -943,6 +944,26 @@
"repo": "xdg-desktop-portal-hyprland", "repo": "xdg-desktop-portal-hyprland",
"type": "github" "type": "github"
} }
},
"zen-browser": {
"inputs": {
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1770438797,
"narHash": "sha256-pwnQTmZswF6bu2/Ie7ajOo8w6rXQwVI954S9WX1UG3w=",
"owner": "youwen5",
"repo": "zen-browser-flake",
"rev": "d396599774bdbafeb86c122dc2c422c7084ea390",
"type": "github"
},
"original": {
"owner": "youwen5",
"repo": "zen-browser-flake",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

View File

@@ -30,6 +30,10 @@
url = "github:Mic92/sops-nix"; url = "github:Mic92/sops-nix";
}; };
systems.url = "github:nix-systems/default"; systems.url = "github:nix-systems/default";
zen-browser = {
inputs.nixpkgs.follows = "nixpkgs";
url = "github:youwen5/zen-browser-flake";
};
}; };
} }