about summary refs log tree commit diff
path: root/pkgs/common-updater
diff options
context:
space:
mode:
authorfigsoda <figsoda@pm.me>2022-12-25 11:31:33 -0500
committerfigsoda <figsoda@pm.me>2022-12-25 11:31:33 -0500
commitcb219cb6d71955f9c14a19f59ec7e57be72d0271 (patch)
tree0d76267e813acc74d56436f54f1575480e1b6c40 /pkgs/common-updater
parent001389279cfd2cde7f0c6b5c39a087119079d9ec (diff)
downloadnixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar.gz
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar.bz2
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar.lz
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar.xz
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.tar.zst
nixlib-cb219cb6d71955f9c14a19f59ec7e57be72d0271.zip
nix-update-script: make attrPath optional
Diffstat (limited to 'pkgs/common-updater')
-rw-r--r--pkgs/common-updater/nix-update.nix8
1 files changed, 4 insertions, 4 deletions
diff --git a/pkgs/common-updater/nix-update.nix b/pkgs/common-updater/nix-update.nix
index bb547302b79a..269e1b6e6455 100644
--- a/pkgs/common-updater/nix-update.nix
+++ b/pkgs/common-updater/nix-update.nix
@@ -1,7 +1,7 @@
-{ nix-update }:
+{ lib, nix-update }:
 
-{ attrPath
-, extraArgs ? []
+{ attrPath ? null
+, extraArgs ? [ ]
 }:
 
-[ "${nix-update}/bin/nix-update" ] ++ extraArgs ++ [ attrPath ]
+[ "${nix-update}/bin/nix-update" ] ++ extraArgs ++ lib.optional (attrPath != null) attrPath