@@ -3,10 +3,14 @@
33
44let
55 python = python3.withPackages (p: [ p.requests ]);
6−in writeScript "update-${packageName}" ''
7− #!${stdenv.shell}
8− set -o errexit
9− PATH=${lib.makeBinPath [ common-updater-scripts coreutils gnugrep gnused python ]}
10− latest_tag=$(python "${./find-latest-version.py}" "${packageName}" "${versionPolicy}" "stable")
11− update-source-version "${attrPath}" "$latest_tag"
12−''
6+ updateScript = writeScript "gnome-update-script" ''
7+ #!${stdenv.shell}
8+ set -o errexit
9+ package_name="$1"
10+ attr_path="$2"
11+ version_policy="$3"
12+ PATH=${lib.makeBinPath [ common-updater-scripts coreutils gnugrep gnused python ]}
13+ latest_tag=$(python "${./find-latest-version.py}" "$package_name" "$version_policy" "stable")
14+ update-source-version "$attr_path" "$latest_tag"
15+ '';
16+in [ updateScript packageName attrPath versionPolicy ]