fuck precommit :(

This commit is contained in:
cnst
2024-07-31 18:10:04 +02:00
parent a67a342617
commit 1b7fef667c
11 changed files with 118 additions and 91 deletions

36
flake.lock generated
View File

@@ -629,11 +629,11 @@
"xdph": "xdph" "xdph": "xdph"
}, },
"locked": { "locked": {
"lastModified": 1722375236, "lastModified": 1722441247,
"narHash": "sha256-8yrkwPN3TbCrtZSD/7GSV2kW9hruIZUQymnpyV15TI4=", "narHash": "sha256-YHVgiYZoaemwEI1/T0r8Q3iTGY1LPFJkBmLDVoqqea0=",
"ref": "refs/heads/main", "ref": "refs/heads/main",
"rev": "3b9b5346b830554aa7470ccf1202a7f3be72d1b4", "rev": "8a5f9bbb394ddeb4be9a9df6248b41b07d84ea66",
"revCount": 5029, "revCount": 5030,
"submodules": true, "submodules": true,
"type": "git", "type": "git",
"url": "https://github.com/hyprwm/Hyprland" "url": "https://github.com/hyprwm/Hyprland"
@@ -644,6 +644,27 @@
"url": "https://github.com/hyprwm/Hyprland" "url": "https://github.com/hyprwm/Hyprland"
} }
}, },
"hyprland-contrib": {
"inputs": {
"nixpkgs": [
"hyprland",
"nixpkgs"
]
},
"locked": {
"lastModified": 1720709712,
"narHash": "sha256-78j/cY+AXoMIqqiNc1vWx237EPfpERAcYsb57ABUbwQ=",
"owner": "hyprwm",
"repo": "contrib",
"rev": "65d42dcbfde2229a75ccdb195c318dfe241f9ade",
"type": "github"
},
"original": {
"owner": "hyprwm",
"repo": "contrib",
"type": "github"
}
},
"hyprland-protocols": { "hyprland-protocols": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -1057,11 +1078,11 @@
"treefmt-nix": "treefmt-nix" "treefmt-nix": "treefmt-nix"
}, },
"locked": { "locked": {
"lastModified": 1722425500, "lastModified": 1722431209,
"narHash": "sha256-nAVezKR8I1ny1dE7qbSdC1Z5uhFVmn6HnOC7eGBiutY=", "narHash": "sha256-qBxvnoQuzhCHTej5JMw1EpjavufRgpMNP9klpO7mbI4=",
"owner": "nix-community", "owner": "nix-community",
"repo": "nixvim", "repo": "nixvim",
"rev": "9314cd46f0f1ff756bae1ae1718c116be894930d", "rev": "8945b3b5e336a42972448e2f07ed5bc465a40c83",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -1130,6 +1151,7 @@
"hardware": "hardware", "hardware": "hardware",
"hm": "hm", "hm": "hm",
"hyprland": "hyprland", "hyprland": "hyprland",
"hyprland-contrib": "hyprland-contrib",
"lanzaboote": "lanzaboote", "lanzaboote": "lanzaboote",
"nix-gaming": "nix-gaming", "nix-gaming": "nix-gaming",
"nixpkgs": "nixpkgs_5", "nixpkgs": "nixpkgs_5",

View File

@@ -60,6 +60,10 @@
# cachyos # cachyos
chaotic.url = "https://flakehub.com/f/chaotic-cx/nyx/*.tar.gz"; chaotic.url = "https://flakehub.com/f/chaotic-cx/nyx/*.tar.gz";
hyprland.url = "git+https://github.com/hyprwm/Hyprland?submodules=1"; hyprland.url = "git+https://github.com/hyprwm/Hyprland?submodules=1";
hyprland-contrib = {
url = "github:hyprwm/contrib";
inputs.nixpkgs.follows = "hyprland/nixpkgs";
};
nix-gaming = { nix-gaming = {
url = "github:fufexan/nix-gaming"; url = "github:fufexan/nix-gaming";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";

View File

@@ -1,4 +1,8 @@
{inputs, ...}: { {
inputs,
pkgs,
...
}: {
imports = [ imports = [
inputs.hyprland.homeManagerModules.default inputs.hyprland.homeManagerModules.default
./land/cnst ./land/cnst

View File

@@ -1,4 +1,22 @@
{pkgs, ...}: { {pkgs, ...}: {
imports = [
./nix
./xdg.nix
./zsh.nix
./fonts.nix
./home-manager.nix
./hyprland.nix
];
security = {
rtkit.enable = true;
pam.services.hyprlock = {};
};
programs.dconf.enable = true;
environment.localBinInPath = true;
console.useXkbConfig = true;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
anyrun anyrun
stow stow

View File

@@ -1,10 +1,6 @@
let let
desktop = [ desktop = [
./core/hyprland.nix ./core
./core/xdg.nix
./core/zsh.nix
./core/fonts.nix
./core/home-manager.nix
./locale ./locale

View File

@@ -7,6 +7,7 @@
system, system,
... ...
}: let }: let
homeDir = builtins.getEnv "HOME";
ifTheyExist = groups: builtins.filter (group: builtins.hasAttr group config.users.groups) groups; ifTheyExist = groups: builtins.filter (group: builtins.hasAttr group config.users.groups) groups;
in { in {
users.users.cnst = { users.users.cnst = {
@@ -33,12 +34,8 @@ in {
]; ];
}; };
programs.dconf.enable = true;
imports = [ imports = [
./system.nix
./hardware-configuration.nix ./hardware-configuration.nix
./substituters.nix
]; ];
boot.kernelPackages = lib.mkForce pkgs.linuxPackages_cachyos; boot.kernelPackages = lib.mkForce pkgs.linuxPackages_cachyos;
@@ -50,10 +47,6 @@ in {
"splash" "splash"
]; ];
environment.sessionVariables = {
FLAKE = "/home/cnst/.nix-config";
};
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
system.stateVersion = lib.mkDefault "23.11"; system.stateVersion = lib.mkDefault "23.11";
} }

View File

@@ -1,28 +0,0 @@
{
nix.settings = {
substituters = [
# high priority since it's almost always used
"https://cache.nixos.org?priority=10"
"https://anyrun.cachix.org"
"https://fufexan.cachix.org"
"https://helix.cachix.org"
"https://hyprland.cachix.org"
"https://nix-community.cachix.org"
"https://nix-gaming.cachix.org"
"https://yazi.cachix.org"
];
trusted-public-keys = [
"cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY="
"anyrun.cachix.org-1:pqBobmOjI7nKlsUMV25u9QHa9btJK65/C8vnO3p346s="
"fufexan.cachix.org-1:LwCDjCJNJQf5XD2BV+yamQIMZfcKWR9ISIFy5curUsY="
"helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs="
"hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
"nix-gaming.cachix.org-1:nbjlureqMbRAxR1gJ/f3hxemL9svXaZF/Ees8vCUUs4="
"yazi.cachix.org-1:Dcdz63NZKfvUCbDGngQDAZq6kOroIrFoyO064uvLh8k="
];
};
}

View File

@@ -3,14 +3,18 @@
outputs, outputs,
lib, lib,
config, config,
pkgs,
... ...
}: { }: let
homeDir = builtins.getEnv "HOME";
in {
environment.variables.FLAKE = "${homeDir}/.nix-config";
programs = { programs = {
nh = { nh = {
enable = true; enable = true;
clean.enable = true; clean.enable = true;
clean.extraArgs = "--keep-since 4d --keep 3"; clean.extraArgs = "--keep-since 4d --keep 3";
flake = "/home/cnst/.nix-config"; flake = "${homeDir}/.nix-config";
}; };
}; };

View File

@@ -44,32 +44,59 @@
inputs.chaotic.nixosModules.default inputs.chaotic.nixosModules.default
]; ];
}; };
toothpc = nixosSystem {
inherit specialArgs;
modules =
desktop
++ [
./toothpc
"${mod}/core"
"${mod}/core/lanzaboote.nix"
"${mod}/core/network/toothpc.nix"
# rog = nixosSystem { "${mod}/hardware/toothpc.nix"
# inherit specialArgs;
# modules =
# laptop
# ++ [
# ./rog
# "${mod}/core/lanzaboote.nix"
# "${mod}/programs/gamemode.nix" "${mod}/services/xserver/toothpc.nix"
# "${mod}/programs/hyprland.nix"
# "${mod}/programs/games.nix"
# "${mod}/services/kanata" "${mod}/extra/gaming.nix"
# {home-manager.users.mihai.imports = homeImports."mihai@rog";} "${mod}/extra/android"
# ]; "${mod}/extra/workstation"
# }; {
home-manager = {
users.toothpick.imports = homeImports."toothpick@toothpc";
extraSpecialArgs = specialArgs;
};
}
# kiiro = nixosSystem { # inputs.agenix.nixosModules.default
# inherit specialArgs; inputs.chaotic.nixosModules.default
# modules = ];
# desktop };
# ++ [ adampad = nixosSystem {
# ./kiiro inherit specialArgs;
# {home-manager.users.mihai.imports = homeImports.server;} modules =
# ]; laptop
# }; ++ [
./adampad
"${mod}/core"
"${mod}/core/network/adampad.nix"
"${mod}/hardware/adampad.nix"
"${mod}/services/xserver/adampad.nix"
"${mod}/services/blueman"
"${mod}/extra/android"
{
home-manager = {
users.adam.imports = homeImports."adam@adampad";
extraSpecialArgs = specialArgs;
};
}
# inputs.agenix.nixosModules.default
inputs.chaotic.nixosModules.default
];
};
}; };
} }

View File

@@ -1,4 +1,6 @@
{config, ...}: { let
homeDir = builtins.getEnv "HOME";
in {
services.xserver = { services.xserver = {
enable = true; enable = true;
videoDrivers = ["amdgpu"]; videoDrivers = ["amdgpu"];
@@ -6,7 +8,7 @@
extraLayouts.hhkbse = { extraLayouts.hhkbse = {
description = "HHKBse by cnst"; description = "HHKBse by cnst";
languages = ["se"]; languages = ["se"];
symbolsFile = /home/cnst/.nix-config/nixos/hosts/cnix/xkb/symbols/hhkbse; symbolsFile = "${homeDir}/.nix-config/nixos/hosts/cnix/xkb/symbols/hhkbse";
}; };
layout = "hhkbse"; layout = "hhkbse";
# dir = "/home/cnst/.nix-config/nixos/xkb"; # dir = "/home/cnst/.nix-config/nixos/xkb";

View File

@@ -1,15 +0,0 @@
{inputs, ...}: {
imports = [inputs.pre-commit-hooks.flakeModule];
perSystem.pre-commit = {
settings.excludes = ["flake.lock"];
settings.hooks = {
alejandra.enable = true;
prettier = {
enable = true;
excludes = [".js" ".md" ".ts"];
};
};
};
}