This gem publishes through RubyGems Trusted Publishing from GitHub Actions.
Run the trusted-publisher setup helper:
bundle exec rake release:trusted_publisherThis runs the RubyGems-maintained configure_trusted_publisher helper for:
- Repository:
autohandai/code-agent-sdk-ruby - Workflow:
.github/workflows/release.yml - Environment:
release
Choose the tag-based release option when prompted. You will still enter RubyGems credentials and MFA once; that owner authorization is the security boundary. After that, GitHub Actions uses short-lived OIDC tokens and no long-lived RubyGems API key is stored in this repository.
If RubyGems asks for an OTP separately, pass it as an environment variable:
RUBYGEMS_OTP=123456 bundle exec rake release:trusted_publisherKeep MFA enabled on the RubyGems owner accounts. Trusted Publishing removes the need for a long-lived API key in GitHub secrets.
- Update
lib/autohand_sdk/version.rb. - Move
CHANGELOG.mdentries fromUnreleasedinto the new version section. - Run the release checks:
bundle exec rake
bundle exec yard
gem build autohand_sdk.gemspec
bundle exec rake package:verify- Commit the version and changelog changes.
- Create and push the release tag:
bundle exec rake release:tagThe task verifies the working tree is clean, runs tests, runs YARD, builds the gem, verifies the package executable, creates the annotated vVERSION tag, and pushes it. The release workflow then rebuilds from the tag and publishes to RubyGems.
The Ruby gem stays small. It does not vendor every Autohand Code CLI binary into the main gem.
Users install the platform CLI with:
bundle exec autohand-sdk install-cliBy default the installer downloads the current platform asset from:
https://github.com/autohandai/code-cli/releases/latest/download
Override the release source when testing a prerelease:
AUTOHAND_CLI_RELEASE_BASE_URL=https://github.com/autohandai/code-cli/releases/download/v0.9.0 \
bundle exec autohand-sdk install-cli --forceThe SDK discovers the CLI in this order:
- Explicit
cli_path:. - A platform binary bundled inside
cli/for custom/private bundles. ~/.autohand/bin/autohand.autohandonPATH.- The platform binary name on
PATH.