add trezor-agent (#4336)

* add `trezor-agent`

* try this

based on https://github.com/romanz/trezor-agent/blob/master/doc/INSTALL.md

* git build dep; fix-shebangs

* one more try

* this seems to work

---------

Co-authored-by: Jacob Heider <jacob@pkgx.dev>
This commit is contained in:
Markus Zoppelt 2023-12-07 19:58:20 +01:00 committed by GitHub
parent 43d80ff351
commit bf69d004da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -0,0 +1,56 @@
distributable:
url: https://github.com/romanz/trezor-agent/archive/refs/tags/v{{version}}.tar.gz
strip-components: 1
versions:
github: romanz/trezor-agent/tags
dependencies:
python.org: ~3.12
libusb.info: ^1
runtime:
env:
PYTHONPATH: '{{prefix}}/lib/python{{deps.python.org.version.marketing}}/site-packages:$PYTHONPATH'
build:
dependencies:
git-scm.org: '*'
script:
- python -m pip install --prefix="{{prefix}}" -e .
- run: |
for AGENT in $AGENTS; do
python -m pip install --prefix="{{prefix}}" -e agents/$AGENT
done
- run: fix-shebangs.ts *
working-directory: ${{prefix}}/bin
skip: fix-patchelf # doesn't like the paths in the libs
env:
AGENTS:
- jade
- keepkey
- ledger
- onlykey
- trezor
provides:
- bin/jade-agent
- bin/jade-gpg
- bin/jade-gpg-agent
- bin/keepkey-agent
- bin/keepkeyctl
- bin/ledger-agent
- bin/ledger-gpg
- bin/ledger-gpg-agent
- bin/onlykey-agent
- bin/onlykey-cli
- bin/onlykey-gpg
- bin/onlykey-gpg-agent
- bin/trezor-agent
- bin/trezor-gpg
- bin/trezor-gpg-agent
- bin/trezor-signify
- bin/trezorctl
# hard to test this, but this will show the python is working
test: trezor-agent --help