lol

linode-cli: 5.26.1 -> 5.45.0

+33 -22
+17 -8
pkgs/tools/virtualization/linode-cli/default.nix
··· 8 8 , requests 9 9 , setuptools 10 10 , terminaltables 11 + , rich 12 + , openapi3 13 + , packaging 11 14 }: 12 15 13 16 let 14 - sha256 = "0r5by5d6wr5zbsaj211s99qg28nr7wm8iri6jxnksx5b375dah6g"; 17 + hash = "sha256-J0L+FTVzYuAqTDOwpoH12lQr03UNo5dsQpd/iUKR40Q="; 15 18 # specVersion taken from: https://www.linode.com/docs/api/openapi.yaml at `info.version`. 16 - specVersion = "4.140.0"; 17 - specSha256 = "0ay54m4aa8bmmpjc7s66rfzqzk4w25h48b9a665y29g67ybb432g"; 19 + specVersion = "4.166.0"; 20 + specHash = "sha256-rUwKQt3y/ALZUoW3eJiiIDJYLQpUHO7Abm0h09ra02g="; 18 21 spec = fetchurl { 19 22 url = "https://raw.githubusercontent.com/linode/linode-api-docs/v${specVersion}/openapi.yaml"; 20 - sha256 = specSha256; 23 + hash = specHash; 21 24 }; 22 25 23 26 in 24 27 25 28 buildPythonApplication rec { 26 29 pname = "linode-cli"; 27 - version = "5.26.1"; 30 + version = "5.45.0"; 31 + pyproject = true; 28 32 29 33 src = fetchFromGitHub { 30 34 owner = "linode"; 31 35 repo = pname; 32 - rev = version; 33 - inherit sha256; 36 + rev = "v${version}"; 37 + inherit hash; 34 38 }; 35 39 36 40 patches = [ ··· 40 44 # remove need for git history 41 45 prePatch = '' 42 46 substituteInPlace setup.py \ 43 - --replace "version=get_version()," "version='${version}'," 47 + --replace "version = get_version()" "version='${version}'," 44 48 ''; 45 49 46 50 propagatedBuildInputs = [ ··· 49 53 requests 50 54 setuptools 51 55 terminaltables 56 + rich 57 + openapi3 58 + packaging 52 59 ]; 53 60 54 61 postConfigure = '' 55 62 python3 -m linodecli bake ${spec} --skip-config 56 63 cp data-3 linodecli/ 64 + echo "${version}" > baked_version 57 65 ''; 58 66 59 67 doInstallCheck = true; ··· 69 77 passthru.updateScript = ./update.sh; 70 78 71 79 meta = with lib; { 80 + mainProgram = "linode-cli"; 72 81 description = "The Linode Command Line Interface"; 73 82 homepage = "https://github.com/linode/linode-cli"; 74 83 license = licenses.bsd3;
+13 -11
pkgs/tools/virtualization/linode-cli/remove-update-check.patch
··· 1 - --- a/linodecli/cli.py 2 - +++ b/linodecli/cli.py 3 - @@ -555,7 +555,7 @@ 4 - if self.debug_request: 5 - self.print_response_debug_info(result) 6 - 7 - - if not self.suppress_warnings: 8 - + if False: 9 - # check the major/minor version API reported against what we were built 10 - # with to see if an upgrade should be available 11 - api_version_higher = False 1 + diff --git a/linodecli/api_request.py b/linodecli/api_request.py 2 + index 4273aa6..3ada5c2 100644 3 + --- a/linodecli/api_request.py 4 + +++ b/linodecli/api_request.py 5 + @@ -305,7 +305,7 @@ def _attempt_warn_old_version(ctx, result): 6 + file=sys.stderr, 7 + ) 8 + 9 + - if api_version_higher: 10 + + if False: 11 + # check to see if there is, in fact, a version to upgrade to. If not, don't 12 + # suggest an upgrade (since there's no package anyway) 13 + new_version_exists = False
+3 -3
pkgs/tools/virtualization/linode-cli/update.sh
··· 18 18 | grep -v -e rc -e list \ 19 19 | cut -d '"' -f4 | sort -rV | head -n 1) 20 20 21 - SHA256=$(nix-prefetch-url --quiet --unpack https://github.com/linode/linode-cli/archive/refs/tags/${VERSION}.tar.gz) 21 + SHA256=$(nix-prefetch-url --quiet --unpack https://github.com/linode/linode-cli/archive/refs/tags/v${VERSION}.tar.gz) 22 22 23 23 setKV () { 24 24 sed -i "s|$1 = \".*\"|$1 = \"${2:-}\"|" ./default.nix 25 25 } 26 26 27 27 setKV specVersion ${SPEC_VERSION} 28 - setKV specSha256 ${SPEC_SHA256} 28 + setKV specHash ${SPEC_SHA256} 29 29 setKV version ${VERSION} 30 - setKV sha256 ${SHA256} 30 + setKV hash ${SHA256}