Closed wasdee closed 5 months ago
Interesting fix proposal. Makes sense to check if gh is authed (already done in setup-git) and use that if so, and if not, then check use the api and check the response for rate limit failure and if so do the auth flow and use gh.
an alternative would be to check if the auth token is mapped via secret or to even guide the user with how to map it via secret, but that is more involved than the above proposal
Implementing now.
Difficulty is that gh doesn't support fetching via a release ID, which at times has been necessary, such as when locking JQ to a specific release ID.
That said, I believe that release IDs were used as filtering via tag name was fragile when jq was not present on the system. In which case, perhaps instead of just passing a release, we should pass the tag, alias, or id of a release so the fetcher can use the appropriate technique.
I believe I've resolved this locally through a thorough rewrite of get-github-release and a partial rewrite of gihtub-download. Will do cross-platform testing tomorrow.
Preliminary Diagnostic
Propose fix
ask user to voluntary sign in the
gh
, andError