mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-27 01:13:05 +00:00
gnome3.updateScript: optimize unfrozen updates
When the updates are not frozen, there is no need to try to extract versions from attributes.
This commit is contained in:
parent
f544c293ec
commit
4239bf17ec
@ -12,7 +12,7 @@ let
|
||||
minorAvailable = builtins.length versionComponents > 1 && builtins.match "[0-9]+" minorVersion != null;
|
||||
nextMinor = builtins.fromJSON minorVersion + 1;
|
||||
upperBound = "${lib.versions.major packageVersion}.${builtins.toString nextMinor}";
|
||||
in lib.optionalString (minorAvailable && freeze) ''--upper-bound="${upperBound}"'';
|
||||
in lib.optionalString (freeze && minorAvailable) ''--upper-bound="${upperBound}"'';
|
||||
updateScript = writeScript "gnome-update-script" ''
|
||||
#!${stdenv.shell}
|
||||
set -o errexit
|
||||
|
Loading…
Reference in New Issue
Block a user