cackle-rs / cackle

A code ACL checker for Rust
Other
194 stars 7 forks source link

Simplify name of binary in GitHub Releases tarballs #18

Open jayvdb opened 1 month ago

jayvdb commented 1 month ago

https://github.com/cackle-rs/cackle/releases/tag/v0.8.0 tarball contains a file cackle-v0.8.0-x86_64-unknown-linux-musl.

Usually github release tarballs only contain the binary, with the expected binary name if cargo install was used. i.e. cargo-acl in this case.

I am trying to add this tool to a github action which installs from github releases, and doesnt have the ability to understand the filename in the tarball. c.f. https://github.com/taiki-e/install-action/pull/604

davidlattimore commented 1 month ago

I assume you've seen cackle-action and need to do something different?

I'm open to changing the name, but I'll need to think about whether that will break the existing action and if so, how best to fix it.

jayvdb commented 1 month ago

Ya, I have seen that. We prefer to use a single github action for installations, and use as few as possible over all - each one becomes SOUP and needs to be risk-accessed & documented.

davidlattimore commented 1 month ago

I just checked and it looks like the binary is already called cargo-acl. It's in a directory that includes the version and target, but the binary has just a simple name. This is consistent with other packages like ripgrep do their releases. Perhaps you can just get tar to strip the directory when you unpack? e.g.

tar -x --strip-components=1 -f something.tar