fix: serve install.sh via docs site and add checksum verification#13
Merged
Conversation
Move install.sh from repo root to public/ so Astro includes it in the docs build output, fixing the 404 at https://atlcli.sh/install.sh. Also adds SHA-256 checksum verification against the checksums.txt published with each release. The script downloads the archive to a temp directory, verifies the checksum, then extracts — failing hard on mismatch. Gracefully degrades when checksums or sha256sum/shasum are unavailable. Adds public/** and src/components/** to the docs workflow path trigger so future static asset changes trigger a redeploy. Fixes #4 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The EXIT trap used single quotes with a local variable, so $tmpdir was out of scope (empty) when the trap fired after install_atlcli returned. Switch to double quotes to capture the path at trap-set time. Use grep -F for the checksum filename lookup to prevent dots in the asset name from being treated as regex wildcards. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
install.shfrom repo root topublic/so Astro includes it in the docs build output, fixing the 404 athttps://atlcli.sh/install.shchecksums.txtpublished with each releasepublic/**andsrc/components/**to the docs workflow path trigger so static asset changes trigger a redeployDetails
The install script was lost during the MkDocs → Astro Starlight migration. Astro serves files from
public/verbatim at the site root, sopublic/install.sh→https://atlcli.sh/install.sh.The checksum verification downloads the archive to a temp directory, verifies the SHA-256 hash, then extracts — failing hard on mismatch. It gracefully degrades when checksums or
sha256sum/shasumare unavailable (warns and continues).Fixes #4
Test plan
bun run docs:buildproducesdist/install.shcurl -fsSL https://atlcli.sh/install.shreturns the script (no 404)curl -fsSL https://atlcli.sh/install.sh | bashinstalls successfully with checksum verification🤖 Generated with Claude Code