From 789c84fc3f212eb75e24190d69ac5854172d8f32 Mon Sep 17 00:00:00 2001 From: Toast Date: Fri, 12 Apr 2024 13:49:02 +0200 Subject: [PATCH 1/4] Common: add missing locales --- roles/common/configuration.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/roles/common/configuration.nix b/roles/common/configuration.nix index 8af3482..b370073 100755 --- a/roles/common/configuration.nix +++ b/roles/common/configuration.nix @@ -48,6 +48,11 @@ # Set up localisation i18n = { defaultLocale = "en_US.UTF-8"; + supportedLocales = [ + "es_US.UTF-8/UTF-8" + "es_ES.UTF-8/UTF-8" + "en_US.UTF-8/UTF-8" + ]; extraLocaleSettings = { LC_NUMERIC = "es_ES.UTF-8"; # am/pm is nice but mm/dd/yy is yucky From cb04535cbf0cf3690eb5a55e6d75fc427f6d4c12 Mon Sep 17 00:00:00 2001 From: Toast Date: Sat, 13 Apr 2024 16:32:27 +0200 Subject: [PATCH 2/4] Machines/WinMax2: run hhd as root --- machines/WinMax2/configuration.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/machines/WinMax2/configuration.nix b/machines/WinMax2/configuration.nix index f8e13d9..b4b1ef2 100755 --- a/machines/WinMax2/configuration.nix +++ b/machines/WinMax2/configuration.nix @@ -60,6 +60,7 @@ }; enable = true; user = "root"; + user = "toast"; }; # Allow unfree packages From 3ccdbe36c9ce122266770d029be689ccb0833ba7 Mon Sep 17 00:00:00 2001 From: Toast Date: Sat, 13 Apr 2024 16:33:10 +0200 Subject: [PATCH 3/4] Flake: add patch to update hhd --- flake.nix | 1 + .../0001-handheld-daemon-1.1.0-2.6.2.patch | 61 +++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.2.patch diff --git a/flake.nix b/flake.nix index a47a42f..24f9efa 100644 --- a/flake.nix +++ b/flake.nix @@ -81,6 +81,7 @@ name = "patched-nixpkgs-unstable"; src = nixpkgs-unstable-raw; patches = [ + ./nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.2.patch ]; }; nixpkgs-patched = nixpkgs-raw.legacyPackages.x86_64-linux.applyPatches { diff --git a/nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.2.patch b/nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.2.patch new file mode 100644 index 0000000..278be1f --- /dev/null +++ b/nixpkgs-patches/0001-handheld-daemon-1.1.0-2.6.2.patch @@ -0,0 +1,61 @@ +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 1/2] 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 2/2] 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 70f9fdecddeaeee06c137ab9a87e4a48d570846f Mon Sep 17 00:00:00 2001 From: Toast Date: Sat, 13 Apr 2024 16:33:37 +0200 Subject: [PATCH 4/4] Machines/WinMax2: remove unneeded hhd override --- machines/WinMax2/configuration.nix | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/machines/WinMax2/configuration.nix b/machines/WinMax2/configuration.nix index b4b1ef2..13ad8f8 100755 --- a/machines/WinMax2/configuration.nix +++ b/machines/WinMax2/configuration.nix @@ -49,17 +49,7 @@ ''; services.handheld-daemon = { - package = pkgs.handheld-daemon.overridePythonAttrs rec { - src = pkgs.fetchFromGitHub { - owner = "hhd-dev"; - repo = "hhd"; - rev = "v${version}"; - hash = "sha256-Ujbou+f/EvHyqpp3FCNqIyZiCEFxSeQfflR3JmRxWFc="; - }; - version = "1.3.13"; - }; enable = true; - user = "root"; user = "toast"; };