diff options
author | Aidan Gauland <aidalgol@fastmail.net> | 2023-11-25 07:46:41 +1300 |
---|---|---|
committer | Aidan Gauland <aidalgol@fastmail.net> | 2023-11-25 07:52:58 +1300 |
commit | 23a9597a0ed8bd4bfef17b6982eefd5603b61b93 (patch) | |
tree | 634572bc487a2199675be2928aace0a1d6a703a2 | |
parent | b3610b80cebc3889836a3e68c945eed3fee92dd1 (diff) |
nile: fix passthru.updateScript
The update script was erroneously carried over from the gogdl derivation code, upon which this derivation was based initially. It should be using unstableGitUpdater instead. Date in current "unstable" version string corrected to UTC.
-rw-r--r-- | pkgs/games/nile/default.nix | 31 |
1 files changed, 3 insertions, 28 deletions
diff --git a/pkgs/games/nile/default.nix b/pkgs/games/nile/default.nix index e3bf056fc3cf1..deae40acf064f 100644 --- a/pkgs/games/nile/default.nix +++ b/pkgs/games/nile/default.nix @@ -1,5 +1,5 @@ { lib -, writeScript +, unstableGitUpdater , buildPythonApplication , fetchFromGitHub , pythonOlder @@ -15,7 +15,7 @@ buildPythonApplication rec { pname = "nile"; - version = "unstable-2023-10-03"; + version = "unstable-2023-10-02"; format = "pyproject"; src = fetchFromGitHub { @@ -55,30 +55,5 @@ buildPythonApplication rec { maintainers = with maintainers; [ aidalgol ]; }; - # Upstream does not create git tags when bumping the version, so we have to - # extract it from the source code on the main branch. - passthru.updateScript = writeScript "gogdl-update-script" '' - #!/usr/bin/env nix-shell - #!nix-shell -i bash -p curl gnused jq common-updater-scripts - set -eou pipefail; - - owner=imLinguin - repo=nile - path='nile/__init__.py' - - version=$( - curl --cacert "${cacert}/etc/ssl/certs/ca-bundle.crt" \ - https://raw.githubusercontent.com/$owner/$repo/main/$path | - sed -n 's/^\s*version\s*=\s*"\([0-9]\.[0-9]\.[0-9]\)"\s*$/\1/p') - - commit=$(curl --cacert "${cacert}/etc/ssl/certs/ca-bundle.crt" \ - https://api.github.com/repos/$owner/$repo/commits?path=$path | - jq -r '.[0].sha') - - update-source-version \ - ${pname} \ - "$version" \ - --file=./pkgs/games/nile/default.nix \ - --rev=$commit - ''; + passthru.updateScript = unstableGitUpdater { }; } |