Repository navigation
Action: run the release binary natively on Windows and macOS (#61) - #72
Merged
Merged
Conversation
runtime: auto (default) keeps the Docker image on Linux and, on Windows and macOS, downloads the self-contained binary of the action's own release, checks it against the published sha256 on every run, and runs it. runtime: binary does that on Linux too. The provenance line names the archive and its sha256. same_commit no longer uses bash-4 lowercasing, for macOS's bash 3.2. CI runs the binary path on ubuntu and, through Git Bash, on windows-latest. Co-Authored-By: Claude Opus 5.5 <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.
Closes #61.
The action ran everything through
docker run, so it was Linux-only. A .NET test job on windows-latest couldn't use it at all, or pair it with dotnet-tia's action, which runs on all three OSes. Every Linux run also paid for an image pull and two or three container starts.runtime: auto | docker | binary(defaultauto)auto: Docker on Linux, or wheneverimage:is set; the binary on Windows and macOS.binary: downloadscifail-<stamp>-<rid>.(zip|tar.gz)of the action's own release (the same version stamp the image tag uses, so pinning the action pins the code) plus its.sha256from that release. The RID comes fromRUNNER_OSandRUNNER_ARCH.unzip, or Windows' owntar.exe(bsdtar reads zip; Git Bash's GNU tar can't), ortar -xzf, intoRUNNER_TOOL_CACHE/cifail/<ver>/<rid>, which persists on self-hosted runners.CIFAIL_BINARYpoints at a binary already on disk.binarywithimage:is refused as a contradiction.binary <archive> sha256 <hash>instead of the image digest.image-digestis empty in binary mode.docker pullare skipped. The tia report is passed by path instead of a mount, andCIFAIL_DB_*reach the binary through the environment.Portability:
same_commit(from #58) used${1,,}, which is bash 4. macOS's/bin/bashis 3.2, so it now lowercases withtr. Runner paths are converted withcygpathunder Git Bash.Verified
cifail-0.5.0-win-x64.zip, verified it, unzipped it and ran it. The provenance line was… | cifail 0.5.0 | binary cifail-0.5.0-win-x64.zip sha256 ab23db3a…, and the outputs wererule=nuget-nu1101,matched=true..sha256was refused, exit 2, and the files were removed.build-test-windowsruns the action script through Git Bash withruntime: autoand stamp 0.5.0, a published release, because this version isn't out yet.docker-smokerunsruntime: binaryon Linux the same way and checks thatbinaryplusimage:is refused.main.Not covered: macOS has no CI job here. Its path is the same tar.gz branch that Linux CI exercises, plus
shasuminstead ofsha256sum.🤖 Generated with Claude Code