From 1bd05aaa4f2218df1b85467d6d6187f09c02b9b3 Mon Sep 17 00:00:00 2001 From: Erwin Boskma Date: Mon, 5 Feb 2024 12:36:00 +0100 Subject: [PATCH] base(probe-rs): Get udev rules from GitHub --- modules/base/default.nix | 5 +---- modules/base/probe-rs/default.nix | 21 +++++++++++++-------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/modules/base/default.nix b/modules/base/default.nix index 3ea0000..093daf8 100644 --- a/modules/base/default.nix +++ b/modules/base/default.nix @@ -11,10 +11,7 @@ let inherit (pkgs.stdenv) mkDerivation; inherit lib; }; - probersRules = pkgs.callPackage ./probe-rs { - inherit (pkgs.stdenv) mkDerivation; - inherit lib; - }; + probersRules = pkgs.callPackage ./probe-rs { inherit lib; }; blink1Rules = pkgs.callPackage ./blink1-udev { inherit (pkgs.stdenv) mkDerivation; inherit lib; diff --git a/modules/base/probe-rs/default.nix b/modules/base/probe-rs/default.nix index c9a245f..a0689cd 100644 --- a/modules/base/probe-rs/default.nix +++ b/modules/base/probe-rs/default.nix @@ -1,20 +1,25 @@ -{ mkDerivation, lib }: -mkDerivation { +{ + stdenv, + lib, + fetchFromGitHub, +}: +stdenv.mkDerivation { pname = "probe-rs-udev-rules"; - version = "20220312131009"; + version = "20240203071125"; - src = builtins.fetchurl { - url = "https://probe.rs/files/69-probe-rs.rules"; - sha256 = "1dLTJ0S5Fxs0y3yme7blGqUG8RwQj/BkZV8PIrmX5gI="; + src = fetchFromGitHub { + owner = "probe-rs"; + repo = "webpage"; + rev = "b0e0d281572b2415db5f51a2951207503e51173d"; + sha256 = "a/ugBQlSAZ6WE7ysFjPsdoPlH+3aZeechHA+NJsBOH4="; }; - dontUnpack = true; dontBuild = true; dontConfigure = true; installPhase = '' mkdir -p $out/lib/udev/rules.d - cp $src $out/lib/udev/rules.d/69-probe-rs.rules + cp $src/src/static/files/69-probe-rs.rules $out/lib/udev/rules.d/69-probe-rs.rules ''; meta = with lib; {