build: harden build-pr.ps1 gitleaks install (macOS arch + tar-from-stdin) - #269
Merged
Merged
Conversation
…din) Fleet-sync of two portability improvements into the local pr.yaml mirror: - macOS darwin/arm64 branch: the non-Windows gitleaks path previously always downloaded the Linux tarball, which fails or installs an incompatible binary on macOS (esp. Apple Silicon). - `tar -xz -f -`: read the archive from stdin explicitly; GNU tar without `-f` defaults to /dev/tape and can hang silently in CI / fresh shells. Dev-tooling script only — not part of the build/test/coverage gate. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the local PR gate script (scripts/build-pr.ps1) to make the on-demand gitleaks install portable and reliable across macOS (including Apple Silicon) and GNU tar environments, aligning with the upstream ETL template behavior.
Changes:
- Select the correct
gitleaksrelease artifact on macOS (darwin_arm64vsdarwin_x64) instead of always downloading the Linux tarball. - Make tar extraction explicitly read from stdin via
tar ... -f -to avoid GNU tar defaulting to/dev/tapeand potentially hanging.
This was referenced Jul 22, 2026
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.
Fleet-sync of two portability improvements into this repo's local
pr.yamlmirror (scripts/build-pr.ps1), found during an audit of the ETL repos' local gates:tar -xz -f -— read the archive from stdin explicitly; GNU tar without-fdefaults to/dev/tapeand can hang silently in CI / fresh shells.Brings this repo's
build-pr.ps1in line with canonical (ETL-FixedWidth #214 / repo-template #432). Dev-tooling script only — not compiled or exercised bypr.yaml's build/test/coverage gate, so no build/test surface. PowerShell hand-verified.