From 52a69d191fa5e2d5ea8ec4fa97874ecf0a321995 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 6 Apr 2024 18:03:23 +0200 Subject: [PATCH] backblaze-b2: 3.17.0 -> 3.18.0 Diff: https://github.com/Backblaze/B2_Command_Line_Tool/compare/refs/tags/v3.17.0...v3.18.0 Changelog: https://github.com/Backblaze/B2_Command_Line_Tool/blob/v3.18.0/CHANGELOG.md --- .../tools/backblaze-b2/default.nix | 30 ++++++++++++------- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/pkgs/development/tools/backblaze-b2/default.nix b/pkgs/development/tools/backblaze-b2/default.nix index 1fd6333a3d50..fadd6a2d4f76 100644 --- a/pkgs/development/tools/backblaze-b2/default.nix +++ b/pkgs/development/tools/backblaze-b2/default.nix @@ -10,23 +10,25 @@ python3Packages.buildPythonApplication rec { pname = "backblaze-b2"; - version = "3.17.0"; - format = "pyproject"; + version = "3.18.0"; + pyproject = true; src = fetchFromGitHub { owner = "Backblaze"; repo = "B2_Command_Line_Tool"; - rev = "v${version}"; - hash = "sha256-Xj7RNe6XM2atijhVasILWRdTzu6xuKBzMllM1z1mFLY="; + rev = "refs/tags/v${version}"; + hash = "sha256-1UXByc3jjp8GN7+aI2GBohJ0DFxgp604QOsXp5GaL4Q="; }; nativeBuildInputs = [ installShellFiles - ] ++ (with python3Packages; [ - pdm-backend - ]); + ]; - propagatedBuildInputs = with python3Packages; [ + build-system = with python3Packages; [ + pdm-backend + ]; + + dependencies = with python3Packages; [ argcomplete arrow b2sdk @@ -53,10 +55,9 @@ python3Packages.buildPythonApplication rec { ''; disabledTestPaths = [ - # requires network + # Test requires network "test/integration/test_b2_command_line.py" "test/integration/test_tqdm_closer.py" - # it's hard to make it work on nix "test/integration/test_autocomplete.py" "test/unit/test_console_tool.py" @@ -64,6 +65,13 @@ python3Packages.buildPythonApplication rec { "test/unit/_cli/test_autocomplete_cache.py" ]; + disabledTests = [ + # Autocomplete is not successful in a sandbox + "test_autocomplete_installer" + "test_help" + "test_install_autocomplete" + ]; + postInstall = lib.optionalString (execName != "b2") '' mv "$out/bin/b2" "$out/bin/${execName}" '' @@ -86,10 +94,10 @@ python3Packages.buildPythonApplication rec { meta = with lib; { description = "Command-line tool for accessing the Backblaze B2 storage service"; - mainProgram = "backblaze-b2"; homepage = "https://github.com/Backblaze/B2_Command_Line_Tool"; changelog = "https://github.com/Backblaze/B2_Command_Line_Tool/blob/v${version}/CHANGELOG.md"; license = licenses.mit; maintainers = with maintainers; [ hrdinka tomhoule ]; + mainProgram = "backblaze-b2"; }; }