From 4d3243498295455658c19a9a5b32b05533903cd8 Mon Sep 17 00:00:00 2001 From: Mohammad Rafiq Date: Fri, 4 Apr 2025 22:08:49 +0800 Subject: [PATCH] refactor: add orpheus --- flake.lock | 86 +----------------------------------------- flake.nix | 33 ++++------------ modules/boot.nix | 7 +++- modules/nix-config.nix | 5 +-- 4 files changed, 16 insertions(+), 115 deletions(-) diff --git a/flake.lock b/flake.lock index 33d3c12..791f5fe 100644 --- a/flake.lock +++ b/flake.lock @@ -179,39 +179,6 @@ "type": "github" } }, - "flake-utils_2": { - "inputs": { - "systems": "systems" - }, - "locked": { - "lastModified": 1731533236, - "narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "11707dc2f618dd54ca8739b309ec4fc024de578b", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flakey-profile": { - "locked": { - "lastModified": 1712898590, - "narHash": "sha256-FhGIEU93VHAChKEXx905TSiPZKga69bWl1VB37FK//I=", - "owner": "lf-", - "repo": "flakey-profile", - "rev": "243c903fd8eadc0f63d205665a92d4df91d42d9d", - "type": "github" - }, - "original": { - "owner": "lf-", - "repo": "flakey-profile", - "type": "github" - } - }, "fromYaml": { "flake": false, "locked": { @@ -364,41 +331,6 @@ "type": "github" } }, - "lix": { - "flake": false, - "locked": { - "lastModified": 1737234286, - "narHash": "sha256-pgDJZjj4jpzkFxsqBTI/9Yb0n3gW+DvDtuv9SwQZZcs=", - "rev": "079528098f5998ba13c88821a2eca1005c1695de", - "type": "tarball", - "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/079528098f5998ba13c88821a2eca1005c1695de.tar.gz?rev=079528098f5998ba13c88821a2eca1005c1695de" - }, - "original": { - "type": "tarball", - "url": "https://git.lix.systems/lix-project/lix/archive/release-2.92.tar.gz" - } - }, - "lix-module": { - "inputs": { - "flake-utils": "flake-utils_2", - "flakey-profile": "flakey-profile", - "lix": "lix", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1742943028, - "narHash": "sha256-fprwZKE1uMzO9tiWWOrmLWBW3GPkMayQfb0xOvVFIno=", - "rev": "868d97695bab9d21f6070b03957bcace249fbe3c", - "type": "tarball", - "url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/868d97695bab9d21f6070b03957bcace249fbe3c.tar.gz" - }, - "original": { - "type": "tarball", - "url": "https://git.lix.systems/lix-project/nixos-module/archive/2.92.0-3.tar.gz" - } - }, "mnw": { "locked": { "lastModified": 1742255973, @@ -566,7 +498,6 @@ "hyprcloser": "hyprcloser", "hyprshaders": "hyprshaders", "impermanence": "impermanence", - "lix-module": "lix-module", "nix-index-database": "nix-index-database", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", @@ -574,7 +505,7 @@ "sops-nix": "sops-nix", "spicetify-nix": "spicetify-nix", "stylix": "stylix", - "systems": "systems_2" + "systems": "systems" } }, "rust-overlay": { @@ -700,21 +631,6 @@ "type": "github" } }, - "systems_2": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, "tinted-foot": { "flake": false, "locked": { diff --git a/flake.nix b/flake.nix index 8b61939..19ab4b5 100644 --- a/flake.nix +++ b/flake.nix @@ -25,10 +25,10 @@ ./modules/security.nix ./modules/users.nix ./modules/networking.nix + ./modules/shell.nix ]; desktopModules = [ ./modules/graphical.nix - ./modules/shell.nix ]; in inputs.nixpkgs.lib.nixosSystem { @@ -54,26 +54,13 @@ ]) ++ (lib.optionals (hostname == "orpheus") [ inputs.nixos-hardware.nixosModules.raspberry-pi-4 - ( - { - pkgs, - lib, - bootDisk, - ... - }: - { - nixpkgs.hostPlatform = lib.mkDefault "aarch64-linux"; - fileSystems."/" = { - device = bootDisk; - fsType = "ext4"; - }; - services.cage = { - enable = true; - user = "rafiq"; - program = "${pkgs.firefox}/bin/firefox -kiosk -private-window https://youtube.com/tv"; - }; - } - ) + { + fileSystems."/" = { + device = "/dev/disk/by-uuid/44444444-4444-4444-8888-888888888888"; + fsType = "ext4"; + }; + nixpkgs.hostPlatform = "aarch64-linux"; + } ]); }; }; @@ -148,9 +135,5 @@ }; url = "github:danth/stylix"; }; - lix-module = { - url = "https://git.lix.systems/lix-project/nixos-module/archive/2.92.0-3.tar.gz"; - inputs.nixpkgs.follows = "nixpkgs"; - }; }; } diff --git a/modules/boot.nix b/modules/boot.nix index c33b1fe..c0d2f8b 100644 --- a/modules/boot.nix +++ b/modules/boot.nix @@ -1,4 +1,9 @@ -{ pkgs, modulesPath, ... }: +{ + pkgs, + modulesPath, + lib, + ... +}: { imports = [ (modulesPath + "/installer/scan/not-detected.nix") diff --git a/modules/nix-config.nix b/modules/nix-config.nix index 4ca2010..22e8fc4 100644 --- a/modules/nix-config.nix +++ b/modules/nix-config.nix @@ -1,7 +1,4 @@ -{ inputs, ... }: { - imports = [ inputs.lix-module.nixosModules.default ]; - system.stateVersion = "24.11"; nixpkgs.config.allowUnfree = true; @@ -10,7 +7,7 @@ experimental-features = [ "nix-command" "flakes" - "pipe-operator" + "pipe-operators" ]; trusted-users = [ "@wheel" ];