zyedidia / eget

Easily install prebuilt binaries from GitHub.
MIT License
1.03k stars 43 forks source link

How to use the file parameter? #8

Closed dufferzafar closed 3 years ago

dufferzafar commented 3 years ago

Some repositories upload a tarball that contains multiple executables.

In such cases, eget picks up the first one it finds.

Can I use the --file parameter to get around this?

This is what I've tried:

> eget Canop/broot --to /spare/ssd/szafar/apps/bin
https://github.com/Canop/broot/releases/download/v1.6.6/broot_1.6.6.zip
Downloading 100% [=========================================================] (17/17 MB, 4.638 MB/s)
Extracted `build/aarch64-linux-android/broot` to `/spare/ssd/szafar/apps/bin/broot`

> eget Canop/broot --to /spare/ssd/szafar/apps/bin --file x86_64-unknown-linux-musl/broot
https://github.com/Canop/broot/releases/download/v1.6.6/broot_1.6.6.zip
Downloading 100% [=========================================================] (17/17 MB, 4.222 MB/s)
target `x86_64-unknown-linux-musl/broot` not found in archive

> eget Canop/broot --to /spare/ssd/szafar/apps/bin --file build/x86_64-unknown-linux-musl/broot
https://github.com/Canop/broot/releases/download/v1.6.6/broot_1.6.6.zip
Downloading 100% [=========================================================] (17/17 MB, 3.470 MB/s)
target `build/x86_64-unknown-linux-musl/broot` not found in archive
zyedidia commented 3 years ago

Thanks, this seems like a good use-case for the -f option, but was not supported before. I have just pushed a commit that should make these commands do what you expect.