gam: 6.58 -> 7.21.01 (#369799)

authored by Sandro and committed by GitHub d2cf0423 f2f6b53a

+16 -19
+16 -19
pkgs/by-name/ga/gam/package.nix
··· 2 2 lib, 3 3 fetchFromGitHub, 4 4 python3, 5 + yubikey-manager, 6 + gitUpdater, 7 + cacert, 5 8 }: 6 9 7 10 python3.pkgs.buildPythonApplication rec { 8 11 pname = "gam"; 9 - version = "6.58"; 10 - format = "other"; 12 + version = "7.21.01"; 13 + pyproject = true; 11 14 12 15 src = fetchFromGitHub { 13 16 owner = "GAM-team"; 14 17 repo = "GAM"; 15 18 tag = "v${version}"; 16 - sha256 = "sha256-AIaPzYavbBlJyi9arZN8HTmUXM7Tef0SIfE07PmV9Oo="; 19 + hash = "sha256-Xj9GTNVuRddu3YQtXD/+yM/MNMxXUkfprtIFAm9SnA4="; 17 20 }; 18 21 19 - sourceRoot = "${src.name}/src"; 22 + build-system = [ python3.pkgs.hatchling ]; 20 23 21 - propagatedBuildInputs = with python3.pkgs; [ 24 + dependencies = with python3.pkgs; [ 25 + arrow 22 26 chardet 23 27 cryptography 24 28 distro 25 29 filelock 26 30 google-api-python-client 27 31 google-auth 32 + google-auth-httplib2 28 33 google-auth-oauthlib 29 34 httplib2 30 35 lxml 31 36 passlib 32 37 pathvalidate 33 38 python-dateutil 34 - setuptools 39 + yubikey-manager 35 40 ]; 36 41 37 42 # Use XDG-ish dirs for configuration. These would otherwise be in the gam ··· 41 46 # at build time and then single quotes the vars in the wrapper, thus they 42 47 # wouldn't get expanded. But using --run allows setting default vars that are 43 48 # evaluated on run and not during build time. 49 + # Detailed on this page: https://github.com/GAM-team/GAM/wiki/gam.cfg 44 50 makeWrapperArgs = [ 51 + ''--set-default GAM_CA_FILE "${cacert}/etc/ssl/certs/ca-bundle.crt"'' 52 + ''--run 'export GAMCFGDIR="''${XDG_CONFIG_HOME:-$HOME/.config}/gam"' '' 45 53 ''--run 'export GAMUSERCONFIGDIR="''${XDG_CONFIG_HOME:-$HOME/.config}/gam"' '' 46 54 ''--run 'export GAMSITECONFIGDIR="''${XDG_CONFIG_HOME:-$HOME/.config}/gam"' '' 47 55 ''--run 'export GAMCACHEDIR="''${XDG_CACHE_HOME:-$HOME/.cache}/gam"' '' 48 56 ''--run 'export GAMDRIVEDIR="$PWD"' '' 49 57 ]; 50 58 51 - installPhase = '' 52 - runHook preInstall 53 - mkdir -p $out/bin 54 - cp gam.py $out/bin/gam 55 - mkdir -p $out/${python3.sitePackages} 56 - cp -r gam $out/${python3.sitePackages} 57 - runHook postInstall 58 - ''; 59 + pythonImportsCheck = [ "gam" ]; 59 60 60 - checkPhase = '' 61 - runHook preCheck 62 - ${python3.interpreter} -m unittest discover --pattern "*_test.py" --buffer 63 - runHook postCheck 64 - ''; 61 + passthru.updateScript = gitUpdater { rev-prefix = "v"; }; 65 62 66 63 meta = { 67 64 description = "Command line management for Google Workspace";