Compare commits
No commits in common. "921f1ad9123bbf394d6746b1c45f3f142c1febec" and "f9d60b9c8b926e5c40cebd0930c9faacc3217048" have entirely different histories.
921f1ad912
...
f9d60b9c8b
3 changed files with 466 additions and 58 deletions
98
flake.lock
generated
98
flake.lock
generated
|
|
@ -25,11 +25,11 @@
|
|||
},
|
||||
"catppuccin": {
|
||||
"locked": {
|
||||
"lastModified": 1713895615,
|
||||
"narHash": "sha256-SVkxhcL0/IN5fNI2dqr702wXOnzktsm0LCEVGRAJQcY=",
|
||||
"lastModified": 1713552048,
|
||||
"narHash": "sha256-RcDJNnxjG9MTQHV/yG7JwPzffFub0JrwP2C1m6LxWFc=",
|
||||
"owner": "catppuccin",
|
||||
"repo": "nix",
|
||||
"rev": "a48e70a31616cb63e4794fd3465bff1835cc4246",
|
||||
"rev": "29bd8a3bda02434bf6ee3edf9ea6edd360a9ce17",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -40,14 +40,16 @@
|
|||
},
|
||||
"catppuccin-vsc": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": [
|
||||
"nixpkgs-unstable-raw"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713966850,
|
||||
"narHash": "sha256-AHAkkTUjk86rED3pQh8i4OiSze+OHe697L0o3zhv89A=",
|
||||
"lastModified": 1713403580,
|
||||
"narHash": "sha256-VP3AiTLL40Zhr+99SwKjIE+ifRy/elhvGIF5W92J+fs=",
|
||||
"owner": "catppuccin",
|
||||
"repo": "vscode",
|
||||
"rev": "75d96f3ae48b249f77124688a026ca5d7eeb5fb2",
|
||||
"rev": "4dd5fa89173bc931e882f21da0de1609f1db9f39",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -118,11 +120,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1714042918,
|
||||
"narHash": "sha256-4AItZA3EQIiSNAxliuYEJumw/LaVfrMv84gYyrs0r3U=",
|
||||
"lastModified": 1713547559,
|
||||
"narHash": "sha256-zju60y4pyYQoRmqhbgkw+jwmKZReVsCNvb8mZxID2Do=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "0c5704eceefcb7bb238a958f532a86e3b59d76db",
|
||||
"rev": "938357cb234e85da37109df2cdd9cc59ab9c1cc0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -138,11 +140,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1714043624,
|
||||
"narHash": "sha256-Xn2r0Jv95TswvPlvamCC46wwNo8ALjRCMBJbGykdhcM=",
|
||||
"lastModified": 1712386041,
|
||||
"narHash": "sha256-dA82pOMQNnCJMAsPG7AXG35VmCSMZsJHTFlTHizpKWQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "86853e31dc1b62c6eeed11c667e8cdd0285d4411",
|
||||
"rev": "d6bb9f934f2870e5cbc5b94c79e9db22246141ff",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -160,11 +162,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1714022840,
|
||||
"narHash": "sha256-i6xZsf7Kvp1n/Sn3nqPY1MJQx0gf80OGQw32PA/aZd8=",
|
||||
"lastModified": 1713333160,
|
||||
"narHash": "sha256-iz4Uz3vykqsZwIY2hxEMfRrc1DvBgxHVCfSxppuj40s=",
|
||||
"owner": "Jovian-Experiments",
|
||||
"repo": "Jovian-NixOS",
|
||||
"rev": "94def3af1d45fe4b142beda3aa59a6a98e62ce9e",
|
||||
"rev": "d3ce25a385ec7ed899ffb282d1e54ccb4ac9ef0d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -233,11 +235,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713869268,
|
||||
"narHash": "sha256-o3CMQeu/S8/4zU0pMtYg51rd1FWdJsI2Xohzng1Ysdg=",
|
||||
"lastModified": 1713067146,
|
||||
"narHash": "sha256-9D20xjblGKEVRVCnM3qWhiizEa9i6OpK6xQJajwcwOQ=",
|
||||
"owner": "Mic92",
|
||||
"repo": "nix-index-database",
|
||||
"rev": "dcb6ac44922858ce3a5b46f77a36d6030181460c",
|
||||
"rev": "93aed67288be60c9ef6133ba2f8de128f4ef265c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -253,11 +255,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713869268,
|
||||
"narHash": "sha256-o3CMQeu/S8/4zU0pMtYg51rd1FWdJsI2Xohzng1Ysdg=",
|
||||
"lastModified": 1713067146,
|
||||
"narHash": "sha256-9D20xjblGKEVRVCnM3qWhiizEa9i6OpK6xQJajwcwOQ=",
|
||||
"owner": "Mic92",
|
||||
"repo": "nix-index-database",
|
||||
"rev": "dcb6ac44922858ce3a5b46f77a36d6030181460c",
|
||||
"rev": "93aed67288be60c9ef6133ba2f8de128f4ef265c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -268,11 +270,11 @@
|
|||
},
|
||||
"nixos-hardware": {
|
||||
"locked": {
|
||||
"lastModified": 1713864415,
|
||||
"narHash": "sha256-/BPDMJEkrsFAFOsQWhwm31wezlgshPFlLBn34KEUdVA=",
|
||||
"lastModified": 1713521961,
|
||||
"narHash": "sha256-EwR8wW9AqJhSIY+0oxWRybUZ32BVKuZ9bjlRh8SJvQ8=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixos-hardware",
|
||||
"rev": "797f8d8082c7cc3259cba7275c699d4991b09ecc",
|
||||
"rev": "5d48925b815fd202781bfae8fb6f45c07112fdb2",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -282,29 +284,13 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1712963716,
|
||||
"narHash": "sha256-WKm9CvgCldeIVvRz87iOMi8CFVB1apJlkUT4GGvA0iM=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "cfd6b5fc90b15709b780a5a1619695a88505a176",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-raw": {
|
||||
"locked": {
|
||||
"lastModified": 1713995372,
|
||||
"narHash": "sha256-fFE3M0vCoiSwCX02z8VF58jXFRj9enYUSTqjyHAjrds=",
|
||||
"lastModified": 1713145326,
|
||||
"narHash": "sha256-m7+IWM6mkWOg22EC5kRUFCycXsXLSU7hWmHdmBfmC3s=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "dd37924974b9202f8226ed5d74a252a9785aedf8",
|
||||
"rev": "53a2c32bc66f5ae41a28d7a9a49d321172af621e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -315,11 +301,11 @@
|
|||
},
|
||||
"nixpkgs-unstable-raw": {
|
||||
"locked": {
|
||||
"lastModified": 1713895582,
|
||||
"narHash": "sha256-cfh1hi+6muQMbi9acOlju3V1gl8BEaZBXBR9jQfQi4U=",
|
||||
"lastModified": 1713248628,
|
||||
"narHash": "sha256-NLznXB5AOnniUtZsyy/aPWOk8ussTuePp2acb9U+ISA=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "572af610f6151fd41c212f897c71f7056e3fb518",
|
||||
"rev": "5672bc9dbf9d88246ddab5ac454e82318d094bb8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -330,11 +316,11 @@
|
|||
},
|
||||
"nur": {
|
||||
"locked": {
|
||||
"lastModified": 1714114197,
|
||||
"narHash": "sha256-f1kMNBUgbY+2/N0YkeouGNYdL7HVsRgcQLf5zL/ayd0=",
|
||||
"lastModified": 1713555937,
|
||||
"narHash": "sha256-ttraBb8XI/iTe0Q6hBTj/W8e+TvsPLACxdw693Gd3hQ=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"rev": "10fc1b8b048fe797ada9302f700590afb457dde2",
|
||||
"rev": "41c9fdae65031c6eaeab1c0a331c0eb9a32376c4",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -353,11 +339,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713952910,
|
||||
"narHash": "sha256-7ICgAfFSQXZlWyhfSrGXAS0rg2YSMKqEO+4EF4lH25I=",
|
||||
"lastModified": 1712872911,
|
||||
"narHash": "sha256-gwYrKMXuUBf5acvTzH7+lXeBbBZYUUEgcLBugHXimuc=",
|
||||
"owner": "toast003",
|
||||
"repo": "plasma-manager",
|
||||
"rev": "13c65048f1f527c7d4ee1f921fa1847129139385",
|
||||
"rev": "8a3ac8690d6f546ec9185e1f5ddbb1f76d63b6b1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -443,11 +429,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1714094499,
|
||||
"narHash": "sha256-SC6tm901h2tzRxd6hfzn5/bgLJ8R4ng39R7SIkg6wlo=",
|
||||
"lastModified": 1713549455,
|
||||
"narHash": "sha256-wMHTvhl7Yl+nNVspchN7e337DBAM2LhHlcHnfAPhGEY=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nix-vscode-extensions",
|
||||
"rev": "e05ff96b9f710d57d7cd60641f0273176debf222",
|
||||
"rev": "15529741a0f9c2b90a725ef5eb2262468a2f40a6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
|||
|
|
@ -56,7 +56,10 @@
|
|||
inputs.home-manager.follows = "home-manager-unstable";
|
||||
};
|
||||
|
||||
catppuccin-vsc.url = "github:catppuccin/vscode";
|
||||
catppuccin-vsc = {
|
||||
url = "github:catppuccin/vscode";
|
||||
inputs.nixpkgs.follows = "nixpkgs-unstable-raw";
|
||||
};
|
||||
|
||||
vscode-extensions = {
|
||||
url = "github:nix-community/nix-vscode-extensions";
|
||||
|
|
@ -77,7 +80,9 @@
|
|||
nixpkgs-unstable-patched = nixpkgs-raw.legacyPackages.x86_64-linux.applyPatches {
|
||||
name = "patched-nixpkgs-unstable";
|
||||
src = nixpkgs-unstable-raw;
|
||||
patches = [];
|
||||
patches = [
|
||||
./nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.4.patch
|
||||
];
|
||||
};
|
||||
nixpkgs-patched = nixpkgs-raw.legacyPackages.x86_64-linux.applyPatches {
|
||||
name = "patched-nixpkgs";
|
||||
|
|
|
|||
417
nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.4.patch
Normal file
417
nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.4.patch
Normal file
|
|
@ -0,0 +1,417 @@
|
|||
From d9e4af9ae8ed30a1ab860915c5c0ff9ae0c16dc1 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Fri, 12 Apr 2024 13:32:24 +0200
|
||||
Subject: [PATCH 01/13] handheld-daemon: 1.1.0 -> 2.6.2
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index bb0c9d65bfe19d..b5f25f339ffb60 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -8,14 +8,14 @@
|
||||
}:
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "handheld-daemon";
|
||||
- version = "1.1.0";
|
||||
+ version = "2.6.2";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "hhd-dev";
|
||||
repo = "hhd";
|
||||
rev = "v${version}";
|
||||
- hash = "sha256-ovLC1BQ98jUaDEMPBzWma4TYSzTF+yE/cMemFdJmqlE=";
|
||||
+ hash = "sha256-fsH8H6ZhiguOWI2t79GnxqAmqL/1m06RQzs+k8bUWcU=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with python3.pkgs; [
|
||||
@@ -26,6 +26,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||
rich
|
||||
setuptools
|
||||
toybox
|
||||
+ xlib
|
||||
];
|
||||
|
||||
# This package doesn't have upstream tests.
|
||||
|
||||
From 2a8d54c511bda43bea18d35d2c08f224f3352a18 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Sat, 13 Apr 2024 15:42:25 +0200
|
||||
Subject: [PATCH 02/13] handheld-daemon: update license
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index b5f25f339ffb60..f0ce6e9648e3e8 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -48,7 +48,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||
homepage = "https://github.com/hhd-dev/hhd/";
|
||||
description = "Linux support for handheld gaming devices like the Legion Go, ROG Ally, and GPD Win";
|
||||
platforms = platforms.linux;
|
||||
- license = licenses.mit;
|
||||
+ license = licenses.gpl3Only;
|
||||
maintainers = with maintainers; [ appsforartists ];
|
||||
mainProgram = "hhd";
|
||||
};
|
||||
|
||||
From 3b96a3c082f6b0e9f7e2eabcc18cf599a0c7eb63 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 00:31:56 +0200
|
||||
Subject: [PATCH 03/13] handheld-daemon: patch generated udev rules to use
|
||||
chmod from nix store
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index f0ce6e9648e3e8..72981284e2e9c1 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -5,6 +5,7 @@
|
||||
, lib
|
||||
, python3
|
||||
, toybox
|
||||
+, coreutils
|
||||
}:
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "handheld-daemon";
|
||||
@@ -38,6 +39,10 @@ python3.pkgs.buildPythonApplication rec {
|
||||
hidapi=${ hidapi }/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
+
|
||||
+ # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
+ chmod=${ coreutils }/bin/chmod
|
||||
+ sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
|
||||
From 6a2060842db04c81b354b49a9c53bfd2262a5af3 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 19:57:10 +0200
|
||||
Subject: [PATCH 04/13] handheld-daemon: remove unneeded coreutils dependency
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 72981284e2e9c1..835c0774469354 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -5,7 +5,6 @@
|
||||
, lib
|
||||
, python3
|
||||
, toybox
|
||||
-, coreutils
|
||||
}:
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "handheld-daemon";
|
||||
@@ -41,7 +40,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
|
||||
# The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
- chmod=${ coreutils }/bin/chmod
|
||||
+ chmod=${ toybox }/bin/chmod
|
||||
sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
|
||||
From c9e8b7cf0260618682c15f7ba601ec9827396ceb Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 20:07:46 +0200
|
||||
Subject: [PATCH 05/13] handheld-daemon: move udev rule comment
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 835c0774469354..d79457057e392c 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -34,12 +34,12 @@ python3.pkgs.buildPythonApplication rec {
|
||||
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
+ # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
postPatch = ''
|
||||
hidapi=${ hidapi }/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
|
||||
- # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
chmod=${ toybox }/bin/chmod
|
||||
sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
From 7bea1eb24a9e84b343c3944318e74ce3442ce40c Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 20:32:43 +0200
|
||||
Subject: [PATCH 06/13] handheld-daemon: 2.6.2 -> 2.6.4
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index d79457057e392c..7801038ea36669 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -8,14 +8,14 @@
|
||||
}:
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "handheld-daemon";
|
||||
- version = "2.6.2";
|
||||
+ version = "2.6.4";
|
||||
pyproject = true;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "hhd-dev";
|
||||
repo = "hhd";
|
||||
rev = "v${version}";
|
||||
- hash = "sha256-fsH8H6ZhiguOWI2t79GnxqAmqL/1m06RQzs+k8bUWcU=";
|
||||
+ hash = "sha256-S77APtE1GGfqnv1IkZdJOSlprPOBtrqVXV60yVMvopg=";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = with python3.pkgs; [
|
||||
|
||||
From b510c5a603c7f2193a4f1c10e03bac6f7f361584 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 21:30:51 +0200
|
||||
Subject: [PATCH 07/13] handheld-daemon: move udev rule comment to the right
|
||||
place this time
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 7801038ea36669..4189bf0483b973 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -32,14 +32,14 @@ python3.pkgs.buildPythonApplication rec {
|
||||
# This package doesn't have upstream tests.
|
||||
doCheck = false;
|
||||
|
||||
- # handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
- # is borrowed from the `hid` derivation.
|
||||
- # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
postPatch = ''
|
||||
+ # handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
+ # is borrowed from the `hid` derivation.
|
||||
hidapi=${ hidapi }/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
|
||||
+ # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
chmod=${ toybox }/bin/chmod
|
||||
sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
From f7b450a4d83aec36be9c1576cb69b92c7895b33d Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Mon, 15 Apr 2024 21:38:38 +0200
|
||||
Subject: [PATCH 08/13] handheld-daemon: fix typo in comment
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 4189bf0483b973..5087698c793430 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -39,7 +39,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
|
||||
- # The generated udev rules point to /bin/chroot, which does not exist in NixOS
|
||||
+ # The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
chmod=${ toybox }/bin/chmod
|
||||
sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
From a581a28a074a3a8bad48ba2883a320bfb02a5062 Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Tue, 16 Apr 2024 19:50:25 +0200
|
||||
Subject: [PATCH 09/13] handheld-daemon: format with nixfmt-rfc-style
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 19 ++++++++++---------
|
||||
1 file changed, 10 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 5087698c793430..52b5729bc6f300 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -1,10 +1,11 @@
|
||||
-{ config
|
||||
-, fetchFromGitHub
|
||||
-, hidapi
|
||||
-, kmod
|
||||
-, lib
|
||||
-, python3
|
||||
-, toybox
|
||||
+{
|
||||
+ config,
|
||||
+ fetchFromGitHub,
|
||||
+ hidapi,
|
||||
+ kmod,
|
||||
+ lib,
|
||||
+ python3,
|
||||
+ toybox,
|
||||
}:
|
||||
python3.pkgs.buildPythonApplication rec {
|
||||
pname = "handheld-daemon";
|
||||
@@ -35,12 +36,12 @@ python3.pkgs.buildPythonApplication rec {
|
||||
postPatch = ''
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
- hidapi=${ hidapi }/lib/
|
||||
+ hidapi=${hidapi}/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
|
||||
# The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
- chmod=${ toybox }/bin/chmod
|
||||
+ chmod=${toybox}/bin/chmod
|
||||
sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
|
||||
From d9b7086a02c8b6a156438d88d86903218907aa9e Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Tue, 16 Apr 2024 20:15:21 +0200
|
||||
Subject: [PATCH 10/13] handheld-daemon: replace sed commands with
|
||||
substituteInPlace
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 12 +++++++-----
|
||||
1 file changed, 7 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index 52b5729bc6f300..356130ec54e07e 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -34,15 +34,17 @@ python3.pkgs.buildPythonApplication rec {
|
||||
doCheck = false;
|
||||
|
||||
postPatch = ''
|
||||
+ # The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
+ substituteInPlace src/hhd/controller/lib/hide.py \
|
||||
+ --replace-fail /bin/chmod ${toybox}/bin/chmod
|
||||
+
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
+ substituteInPlace src/hhd/controller/lib/hid.py \
|
||||
+ --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
+
|
||||
hidapi=${hidapi}/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
- sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
-
|
||||
- # The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
- chmod=${toybox}/bin/chmod
|
||||
- sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
|
||||
From 20753a73d1a20cf5b67bc7cc51572807c0eda9fc Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Tue, 16 Apr 2024 20:29:56 +0200
|
||||
Subject: [PATCH 11/13] handheld-daemon: trim out trailing whitespace
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index b734034a439dab..db6c46a7e8055c 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -41,9 +41,9 @@ python3.pkgs.buildPythonApplication rec {
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
substituteInPlace src/hhd/controller/lib/hid.py \
|
||||
- --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
-
|
||||
- hidapi=${hidapi}/lib/
|
||||
+ --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
+
|
||||
+ hidapi=${hidapi}/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
'';
|
||||
|
||||
|
||||
From cb2fa9a66110a6deb4f66c2dfd146b2895f932bd Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Tue, 16 Apr 2024 21:04:48 +0200
|
||||
Subject: [PATCH 12/13] handheld-daemon: fix indenting
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index db6c46a7e8055c..ad0554bec36d52 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -41,9 +41,9 @@ python3.pkgs.buildPythonApplication rec {
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
substituteInPlace src/hhd/controller/lib/hid.py \
|
||||
- --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
+ --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
|
||||
- hidapi=${hidapi}/lib/
|
||||
+ hidapi=${hidapi}/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
'';
|
||||
|
||||
|
||||
From d9b487ae609a368378c1a9d89a5441c5c44121df Mon Sep 17 00:00:00 2001
|
||||
From: Toast <39011842+toast003@users.noreply.github.com>
|
||||
Date: Wed, 17 Apr 2024 09:19:43 +0200
|
||||
Subject: [PATCH 13/13] handheld-daemon: undo refactor
|
||||
|
||||
---
|
||||
pkgs/by-name/ha/handheld-daemon/package.nix | 12 +++++-------
|
||||
1 file changed, 5 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/pkgs/by-name/ha/handheld-daemon/package.nix b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
index ad0554bec36d52..246e3879bb5cfa 100644
|
||||
--- a/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
+++ b/pkgs/by-name/ha/handheld-daemon/package.nix
|
||||
@@ -34,17 +34,15 @@ python3.pkgs.buildPythonApplication rec {
|
||||
doCheck = false;
|
||||
|
||||
postPatch = ''
|
||||
- # The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
- substituteInPlace src/hhd/controller/lib/hide.py \
|
||||
- --replace-fail /bin/chmod ${toybox}/bin/chmod
|
||||
-
|
||||
# handheld-daemon contains a fork of the python module `hid`, so this hook
|
||||
# is borrowed from the `hid` derivation.
|
||||
- substituteInPlace src/hhd/controller/lib/hid.py \
|
||||
- --replace-fail libhidapi ${hidapi}/lib/libhidapi
|
||||
-
|
||||
hidapi=${hidapi}/lib/
|
||||
test -d $hidapi || { echo "ERROR: $hidapi doesn't exist, please update/fix this build expression."; exit 1; }
|
||||
+ sed -i -e "s|libhidapi|$hidapi/libhidapi|" src/hhd/controller/lib/hid.py
|
||||
+
|
||||
+ # The generated udev rules point to /bin/chmod, which does not exist in NixOS
|
||||
+ chmod=${toybox}/bin/chmod
|
||||
+ sed -i -e "s|/bin/chmod|$chmod|" src/hhd/controller/lib/hide.py
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
Loading…
Add table
Add a link
Reference in a new issue