jaxxstorm / action-install-gh-release

GitHub Action to install the Github Release binaries
Apache License 2.0
67 stars 29 forks source link

Handle releases nested within single directories #88

Closed orf closed 4 weeks ago

orf commented 1 month ago

Hey, thank you for this awesome action ❤️.

I was trying to use it with Hyperfine:

      - name: install hyperfine
        uses: jaxxstorm/action-install-gh-release@v1
        with:
          repo: sharkdp/hyperfine

However this fails, because the extracted release file contains a single directory called hyperfine-v1.18.0-x86_64-unknown-linux-gnu/

As a workaround, you can do:

      - name: install hyperfine
        uses: jaxxstorm/action-install-gh-release@v1
        with:
          repo: sharkdp/hyperfine
          tag: v1.18.0
          binaries-location: hyperfine-v1.18.0-x86_64-unknown-linux-gnu

However this isn't ideal. It would be awesome if the action could detect if the release file has a single extracted directory, and use that to find the binaries automatically?

jaxxstorm commented 4 weeks ago

I don't have any plans to add logic for the myriad ways that directories can be placed in an archive, I think binaries-location is a fine way of handling this. Closing