-
Notifications
You must be signed in to change notification settings - Fork 46
Remove validation, use "latest" as default version for install script #13668
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
@copilot remove validation and use "latest" as the default version if not provided. |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR updates the installation flow for gh-aw to avoid using the GitHub Releases API (which can be blocked by MITM proxies) and instead rely on GitHub’s releases/latest/download redirect pattern, while keeping the CLI and GitHub Action installer behavior in sync. It also updates tests and documentation to match the new default of using "latest" when no version is specified.
Changes:
- Simplified both install scripts to default to
VERSION="latest"when no version is specified, and construct download/checksum URLs using thereleases/latest/downloadpattern instead of querying the GitHub API. - Removed the release existence validation logic that depended on the GitHub API, while keeping the retry-capable
fetch_release_datahelper available for any future use. - Extended the install script tests to verify the new
"latest"behavior and updated troubleshooting docs with guidance for restricted network environments and manual installation instructions.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
install-gh-aw.sh |
Switches default behavior to use "latest" (with a log message), removes API-based version/validation logic, and constructs download/checksum URLs using releases/latest/download when VERSION=latest, aligning the script with environments where api.github.com is blocked. |
actions/setup-cli/install.sh |
Mirrors the same "latest"-by-default and non-API URL construction logic used in install-gh-aw.sh, ensuring the GitHub Action’s installer behaves consistently and avoids api.github.com calls. |
scripts/test-install-script.sh |
Adds a new test block to assert that the main install script uses "latest" by default, builds URLs with releases/latest/download, and no longer contains API validation logic, guarding the new behavior. |
docs/src/content/docs/troubleshooting/common-issues.md |
Documents the new "latest"-based installation flow, explains why it works in restricted environments, and provides explicit examples for installing specific versions and manual binary installation using the new URL scheme. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
The install script fails in environments where
api.github.comis blocked by MITM proxies (e.g., GitHub Copilot agent runtime, corporate networks), returning HTTP 403 on release API calls.Changes
/releases/latest/download/URL patternUsage
This approach works seamlessly in restricted network environments by using GitHub's release download redirects instead of API calls.
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.