Skip to content

fix: add gibo --version assertion after install#63

Open
kitsuyui wants to merge 2 commits into
mainfrom
fix/audit-action-exit-code-and-cli-contract-not-curated-001
Open

fix: add gibo --version assertion after install#63
kitsuyui wants to merge 2 commits into
mainfrom
fix/audit-action-exit-code-and-cli-contract-not-curated-001

Conversation

@kitsuyui

Copy link
Copy Markdown
Member

Summary

After copying the binary and setting its executable bit, the action now calls
gibo --version and redirects the output to stderr. This makes the
post-install assertion explicit: the binary is present, executable,
ABI-compatible with the runner, and reports the expected version.

Previously the action relied on gibo root — called immediately after to
locate the boilerplates directory — as an indirect install check. That call
verified the binary worked but was not designed as an assertion and its
purpose was not visible in the log. Calling --version first makes the
intent clear and surfaces the installed version in the Actions step output.

Changes

  • action.yml: add "${bin_dir}/${executable}" --version >&2 between
    chmod +x and the gibo root call.

Test plan

  • CI passes on all matrix platforms (Linux x64/arm64, macOS x64/arm64, Windows x64)
  • The Actions log shows gibo v3.0.22 (or the overridden version) on stderr
  • No behaviour change on the happy path; failure of --version fails the step fast before any further state is created

kitsuyui added 2 commits June 17, 2026 11:28
Explicitly calls `gibo --version` after copying and chmod-ing the
binary. This verifies the installed binary is executable, ABI-compatible
with the runner, and reports the expected version — making the implicit
"it works" contract explicit and logged to stderr.

Previously the action relied on `gibo root` (called to locate the
boilerplates directory) as an indirect install verification. Calling
`--version` first makes the assertion intentional and surfaced in the
Actions log.
gibo (cobra-based CLI) exposes its version via the 'version' subcommand,
not a '--version' flag. The previous assertion failed with
'unknown flag: --version' (exit 1), breaking the install step on every
runner. Switch to 'gibo version', which prints the version and exits 0.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant