diff options
author | Attila Lendvai <attila@lendvai.name> | 2021-11-28 21:23:24 +0100 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2021-11-28 21:31:09 +0100 |
commit | d3448fafea40b6c53de34696d7e481811de36c09 (patch) | |
tree | d037970ca92354dbbe3d2514bf45e27e3f740df5 /gnu | |
parent | 857098830bcfcb864d0375d59fbf79c2dbfd6c5b (diff) | |
download | guix-d3448fafea40b6c53de34696d7e481811de36c09.tar.gz |
gnu: trezor-agent: Update to 0.11.0.
* gnu/packages/finance.scm (trezor-agent): Update to 0.11.0. [source]: Use GitHub repository. [native-inputs]: Remove python-hidapi. Add python-attrs. Signed-off-by: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/packages/finance.scm | 40 |
1 files changed, 32 insertions, 8 deletions
diff --git a/gnu/packages/finance.scm b/gnu/packages/finance.scm index 08639e26d5..2492f04741 100644 --- a/gnu/packages/finance.scm +++ b/gnu/packages/finance.scm @@ -1102,16 +1102,40 @@ the KeepKey Hardware Wallet.") (define-public trezor-agent (package (name "trezor-agent") - (version "0.10.0") + (version "0.11.0") (source (origin - (method url-fetch) - (uri (pypi-uri "trezor_agent" version)) + (method git-fetch) + (uri (git-reference + (url "https://github.com/romanz/trezor-agent") + ;; The version mismatch is not a mistake. Multiple python + ;; apps/packages are in the same git repo, and they have + ;; different versions. The git tag seems to track libagent, + ;; i.e. python-trezor-agent in the Guix namespace. + ;; See e.g. ./agents/trezor/setup.py + (commit "v0.14.2"))) (sha256 - (base32 - "144657c7bn0a667dq5fv5r6j7iilxf3h9agj29v1m2qpq40g0az8")))) + (base32 "0nl44ldfw9s2v3p7g5bldfw3ds2hz9r28j42bpnp8bj0v5na3ivk")) + (modules + '((guix build utils) + (ice-9 ftw) + (srfi srfi-1) + (srfi srfi-26))) + (snippet + '(begin + ;; Delete everything except ./agents/trezor/ + (for-each delete-file-recursively + (filter (lambda (full-name) + (not (string-prefix? "./agents/trezor/" full-name))) + (find-files "."))) + ;; Move ./agents/trezor/* to the toplevel + (for-each (lambda (file-name) + (rename-file (string-append "./agents/trezor/" file-name) + (string-append "./" file-name))) + (scandir "./agents/trezor/" + (negate (cut member <> '("." "..") string=)))) + (delete-file-recursively "./agents"))))) (arguments - ;; Tests fail with "AttributeError: module 'attr' has no attribute 's'". `(#:phases (modify-phases %standard-phases (add-after 'wrap 'fixup-agent-py @@ -1128,13 +1152,13 @@ the KeepKey Hardware Wallet.") ;; Overwrite the wrapped one with the real thing. (install-file "./trezor_agent.py" (string-append out "/bin")) - #t)))))) + #t)))))) (build-system python-build-system) (inputs `(("python-trezor" ,python-trezor) ("python-trezor-agent" ,python-trezor-agent))) (native-inputs - `(("python-hidapi" ,python-hidapi))) + `(("python-attrs" ,python-attrs))) (home-page "https://github.com/romanz/trezor-agent") (synopsis "Using Trezor as hardware SSH/GPG agent") (description "This package allows using Trezor as a hardware SSH/GPG |