diff --git a/flake.lock b/flake.lock index 48bfdb3..0660fe5 100644 --- a/flake.lock +++ b/flake.lock @@ -20,6 +20,21 @@ "type": "github" } }, + "crane": { + "locked": { + "lastModified": 1737689766, + "narHash": "sha256-ivVXYaYlShxYoKfSo5+y5930qMKKJ8CLcAoIBPQfJ6s=", + "owner": "ipetkov", + "repo": "crane", + "rev": "6fe74265bbb6d016d663b1091f015e2976c4a527", + "type": "github" + }, + "original": { + "owner": "ipetkov", + "repo": "crane", + "type": "github" + } + }, "doll-repair": { "inputs": { "flake-parts": "flake-parts", @@ -63,7 +78,7 @@ }, "fedi-emotes_2": { "inputs": { - "nixpkgs": "nixpkgs_2" + "nixpkgs": "nixpkgs_3" }, "locked": { "lastModified": 1714013418, @@ -209,6 +224,24 @@ "inputs": { "systems": "systems_2" }, + "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" + } + }, + "flake-utils_3": { + "inputs": { + "systems": "systems_3" + }, "locked": { "lastModified": 1726560853, "narHash": "sha256-X6rJYSESBVr3hBoH0WbKE5KvhPU5bloyZ2L4K60/fPQ=", @@ -223,9 +256,9 @@ "type": "github" } }, - "flake-utils_3": { + "flake-utils_4": { "inputs": { - "systems": "systems_3" + "systems": "systems_4" }, "locked": { "lastModified": 1731533236, @@ -349,6 +382,27 @@ "type": "github" } }, + "lenovo-rgb": { + "inputs": { + "crane": "crane", + "flake-utils": "flake-utils_2", + "nixpkgs": "nixpkgs_2", + "rust-overlay": "rust-overlay_2" + }, + "locked": { + "lastModified": 1740256865, + "narHash": "sha256-KhcnH5vgn9QMXeiYmpk1jtqr3hEAOuLoRuLmhVvr5FA=", + "owner": "4jx", + "repo": "l5p-keyboard-rgb", + "rev": "2fd9dba693f9bed89fb07c672dd6c522e6cf4301", + "type": "github" + }, + "original": { + "owner": "4jx", + "repo": "l5p-keyboard-rgb", + "type": "github" + } + }, "lightrunner-emotes": { "inputs": { "fedi-emotes": "fedi-emotes_2", @@ -406,7 +460,7 @@ }, "lix-module": { "inputs": { - "flake-utils": "flake-utils_2", + "flake-utils": "flake-utils_3", "flakey-profile": "flakey-profile", "lix": "lix", "nixpkgs": [ @@ -443,7 +497,7 @@ "nixos-generators": { "inputs": { "nixlib": "nixlib", - "nixpkgs": "nixpkgs_3" + "nixpkgs": "nixpkgs_4" }, "locked": { "lastModified": 1740947705, @@ -600,6 +654,22 @@ } }, "nixpkgs_2": { + "locked": { + "lastModified": 1737717945, + "narHash": "sha256-ET91TMkab3PmOZnqiJQYOtSGvSTvGeHoegAv4zcTefM=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "ecd26a469ac56357fd333946a99086e992452b6a", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { "locked": { "lastModified": 1713596654, "narHash": "sha256-LJbHQQ5aX1LVth2ST+Kkse/DRzgxlVhTL1rxthvyhZc=", @@ -615,7 +685,7 @@ "type": "github" } }, - "nixpkgs_3": { + "nixpkgs_4": { "locked": { "lastModified": 1736657626, "narHash": "sha256-FWlPMUzp0lkQBdhKlPqtQdqmp+/C+1MBiEytaYfrCTY=", @@ -631,7 +701,7 @@ "type": "github" } }, - "nixpkgs_4": { + "nixpkgs_5": { "locked": { "lastModified": 1741513245, "narHash": "sha256-7rTAMNTY1xoBwz0h7ZMtEcd8LELk9R5TzBPoHuhNSCk=", @@ -647,7 +717,7 @@ "type": "github" } }, - "nixpkgs_5": { + "nixpkgs_6": { "locked": { "lastModified": 1731763621, "narHash": "sha256-ddcX4lQL0X05AYkrkV2LMFgGdRvgap7Ho8kgon3iWZk=", @@ -708,7 +778,7 @@ }, "nuschtosSearch": { "inputs": { - "flake-utils": "flake-utils_3", + "flake-utils": "flake-utils_4", "ixx": "ixx", "nixpkgs": [ "nixvim", @@ -785,12 +855,13 @@ "home-manager": "home-manager", "iceshrimp": "iceshrimp", "iceshrimp-withdrawal": "iceshrimp-withdrawal", + "lenovo-rgb": "lenovo-rgb", "lightrunner-emotes": "lightrunner-emotes", "linger": "linger", "lix-module": "lix-module", "nixos-generators": "nixos-generators", "nixos-hardware": "nixos-hardware", - "nixpkgs": "nixpkgs_4", + "nixpkgs": "nixpkgs_5", "nixpkgs-master": "nixpkgs-master", "nixpkgs-stable": "nixpkgs-stable", "nixpkgs-unstable": "nixpkgs-unstable", @@ -819,6 +890,27 @@ "type": "github" } }, + "rust-overlay_2": { + "inputs": { + "nixpkgs": [ + "lenovo-rgb", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1737771740, + "narHash": "sha256-lWIdF4qke63TdCHnJ0QaUHfG8YvsDrBqzL4jiHYQd+Y=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "cfaaa1dddd280af09aca84af84612fbccd986ae2", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + }, "saerro": { "inputs": { "flake-parts": "flake-parts_5", @@ -842,7 +934,7 @@ }, "sops-nix": { "inputs": { - "nixpkgs": "nixpkgs_5" + "nixpkgs": "nixpkgs_6" }, "locked": { "lastModified": 1741644481, @@ -903,6 +995,21 @@ "type": "github" } }, + "systems_4": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "tachikoma": { "inputs": { "nixpkgs": [ diff --git a/flake.nix b/flake.nix index 51ea2a5..203ee63 100644 --- a/flake.nix +++ b/flake.nix @@ -36,7 +36,7 @@ nixos-generators.url = "github:nix-community/nixos-generators"; nixos-hardware.url = "github:nixos/nixos-hardware/master"; flake-utils.url = "github:numtide/flake-utils"; - # lenovo-rgb.url = "github:4jx/l5p-keyboard-rgb"; + lenovo-rgb.url = "github:4jx/l5p-keyboard-rgb"; # Iceshrimpy iceshrimp = { diff --git a/home-manager/features/wine.nix b/home-manager/features/wine.nix deleted file mode 100644 index a4dd6e6..0000000 --- a/home-manager/features/wine.nix +++ /dev/null @@ -1,7 +0,0 @@ -{ pkgs, ... }: { - home.packages = with pkgs; [ - wine - winetricks - wineWowPackages.waylandFull - ]; -} diff --git a/home-manager/noe/hosts/unicorn.nix b/home-manager/noe/hosts/unicorn.nix index e431317..8bd7768 100644 --- a/home-manager/noe/hosts/unicorn.nix +++ b/home-manager/noe/hosts/unicorn.nix @@ -1,4 +1,4 @@ -{ pkgs, ... }: { +{ pkgs, config, ... }: { imports = [ ../common ../common/home-user.nix @@ -6,7 +6,6 @@ ../../features/kitty.nix ../../features/vesktop ../../features/retroarch.nix - ../../features/wine.nix ]; home.packages = with pkgs; [ diff --git a/nixos/features/no-rgb.nix b/nixos/features/no-rgb.nix index 630477a..c7d1497 100644 --- a/nixos/features/no-rgb.nix +++ b/nixos/features/no-rgb.nix @@ -20,7 +20,7 @@ in { ExecStart = "${no-rgb}/bin/no-rgb"; Type = "oneshot"; }; - wantedBy = [ "multi-user.target" ]; + after = [ "multi-user.target" ]; }; }; } diff --git a/nixos/features/wine.nix b/nixos/features/wine.nix new file mode 100644 index 0000000..5589357 --- /dev/null +++ b/nixos/features/wine.nix @@ -0,0 +1,17 @@ +{ pkgs, config, lib, ... }: let + winePkg = config.internal.wine; +in { + options = { + internal.wine = lib.mkOption { + type = lib.types.package; + default = pkgs.wineWowPackages.waylandFull; + }; + }; + + config = { + environment.systemPackages = [ + pkgs.winetricks + winePkg + ]; + }; +} diff --git a/nixos/hosts/unicorn/default.nix b/nixos/hosts/unicorn/default.nix index 73e2be2..6baaacf 100644 --- a/nixos/hosts/unicorn/default.nix +++ b/nixos/hosts/unicorn/default.nix @@ -15,6 +15,8 @@ ../../features/telemetry ../../features/wifi.nix ../../features/protonvpn.nix + ../../features/wine.nix + ./rgb.nix inputs.nixos-hardware.nixosModules.common-cpu-amd inputs.nixos-hardware.nixosModules.common-gpu-amd @@ -44,10 +46,6 @@ nvidiaBusId = "PCI:1:0:0"; }; - environment.systemPackages = with pkgs; [ - openrgb - ]; - # √(2560² + 1600²) px / 16 in ≃ 189 dpi services.xserver.dpi = 189; } diff --git a/nixos/hosts/unicorn/rgb.nix b/nixos/hosts/unicorn/rgb.nix index 088ea75..4a93c6d 100644 --- a/nixos/hosts/unicorn/rgb.nix +++ b/nixos/hosts/unicorn/rgb.nix @@ -1,8 +1,12 @@ { inputs, pkgs, ... }: let - config = pkgs.writeFile "config.rgb" ''{"name":"awawa2","rgb_zones":[{"rgb":[255,0,0],"enabled":true},{"rgb":[39,5,5],"enabled":true},{"rgb":[26,9,0],"enabled":true},{"rgb":[192,95,0],"enabled":true}],"effect":"Static","direction":"Left","speed":1,"brightness":"Low"}''; + pkg = inputs.lenovo-rgb.packages.${pkgs.system}.default; in { systemd.services.rgb = { description = "rgb"; - serviceConfig = {}; + serviceConfig = { + ExecStart = "${pkg}/bin/legion-kb-rgb set --effect Static --colors 255,0,0,39,5,5,26,9,0,192,95,0"; + Type = "oneshot"; + }; + after = [ "multi-user.target" ]; }; } diff --git a/pkgs/beyond-all-reason.nix b/pkgs/beyond-all-reason.nix index 710190a..f7452e7 100644 --- a/pkgs/beyond-all-reason.nix +++ b/pkgs/beyond-all-reason.nix @@ -26,6 +26,7 @@ exec = pname; icon = pname; desktopName = pname; + type = "Applications"; comment = "Open Source RTS game"; categories = [ "Game" diff --git a/pkgs/mspaint/bin/mfc42u.dll b/pkgs/mspaint/bin/mfc42u.dll new file mode 100644 index 0000000..09413f3 Binary files /dev/null and b/pkgs/mspaint/bin/mfc42u.dll differ diff --git a/pkgs/mspaint/mspaint.exe b/pkgs/mspaint/bin/mspaint.exe similarity index 100% rename from pkgs/mspaint/mspaint.exe rename to pkgs/mspaint/bin/mspaint.exe diff --git a/pkgs/mspaint/default.nix b/pkgs/mspaint/default.nix index 19ee69d..7627652 100644 --- a/pkgs/mspaint/default.nix +++ b/pkgs/mspaint/default.nix @@ -1,10 +1,22 @@ -{ pkgs, ... }: let +{ pkgs, wine ? pkgs.wine, ... }: let wrapped = pkgs.writeShellScriptBin "mspaint" '' - ${pkgs.wine}/bin/wine ${./mspaint.exe} + ${wine}/bin/wine ${./bin}/mspaint.exe ''; -in pkgs.makeDesktopItem { - name = "mspaint"; - desktopName = "mspaint"; - type = "Application"; - exec = "${wrapped}/bin/mspaint"; -} \ No newline at end of file + desktopItem = pkgs.makeDesktopItem { + name = "mspaint"; + desktopName = "mspaint"; + type = "Application"; + categories = [ "Graphics" ]; + exec = "${wrapped}/bin/mspaint"; + }; +in pkgs.stdenvNoCC.mkDerivation { + pname = "mspaint"; + version = "0.0.0"; + src = wrapped; + + nativeBuildInputs = [ + pkgs.copyDesktopItems + ]; + + desktopItems = [ desktopItem ]; +} diff --git a/settings.json b/settings.json new file mode 100644 index 0000000..b0877e6 --- /dev/null +++ b/settings.json @@ -0,0 +1 @@ +{"profiles":[],"effects":[],"current_profile":{"name":"awawa2","rgb_zones":[{"rgb":[255,0,0],"enabled":true},{"rgb":[39,5,5],"enabled":true},{"rgb":[26,9,0],"enabled":true},{"rgb":[192,95,0],"enabled":true}],"effect":"Static","direction":"Left","speed":1,"brightness":"Low"}} \ No newline at end of file