mirror of
https://github.com/NixOS/nixos-hardware.git
synced 2026-12-06 07:53:30 +01:00
mnt/reform: convert update patches to derivation
This commit is contained in:
2 files changed
+8
-4
No files matched your search
@@ -1,4 +1,5 @@
|
|||||||
{
|
{
|
||||||
|
runCommand,
|
||||||
lib,
|
lib,
|
||||||
fetchFromGitLab,
|
fetchFromGitLab,
|
||||||
}:
|
}:
|
||||||
@@ -7,6 +8,8 @@ let
|
|||||||
sources = lib.importJSON ./sources.json;
|
sources = lib.importJSON ./sources.json;
|
||||||
reformDebianPackages = fetchFromGitLab sources.reformDebianPackages;
|
reformDebianPackages = fetchFromGitLab sources.reformDebianPackages;
|
||||||
in
|
in
|
||||||
map (lib.removePrefix "${reformDebianPackages}/") (
|
runCommand "mnt-reform-kernel-patches" { } ''
|
||||||
lib.filesystem.listFilesRecursive "${reformDebianPackages}/linux/patches${lib.versions.majorMinor sources.modDirVersion}"
|
shopt -s globstar
|
||||||
)
|
cd ${reformDebianPackages}
|
||||||
|
echo "[ $(printf '"%s"' linux/patches${lib.versions.majorMinor sources.modDirVersion}/**/*.patch) ]" > $out
|
||||||
|
''
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env sh
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
nix eval .#mnt-reform-kernel-patches > kernelPatches.nix
|
nix build .#mnt-reform-kernel-patches
|
||||||
|
cp result kernelPatches.nix
|
||||||
nix fmt kernelPatches.nix
|
nix fmt kernelPatches.nix
|
||||||
Reference in new issue
Block a user