Skip to content

Add RubyGems trusted publisher setup task - #35

Merged
samuel-williams-shopify merged 1 commit into
mainfrom
setup-trusted-publisher
Sep 27, 2026
Merged

samuel-williams-shopify merged 1 commit into
mainfrom
setup-trusted-publisher

Conversation

@samuel-williams-shopify

@samuel-williams-shopify samuel-williams-shopify commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

Add bake gem:github:setup:publisher so maintainers can register an existing gem's RubyGems trusted publisher directly from its gemspec and config/release.yaml. The task reuses an exact matching registration, preserves other publishers, and reports API failures instead of treating them as missing configuration.

Reuse RubyGems login and MFA support with a scoped, 15-minute session key kept in memory, or an explicitly supplied API key. Add gem:github:setup:plan publisher=true to check registration; the default plan does not authenticate to RubyGems. Update the setup guide, distributed context, and release notes.

Automated validation uses mocked RubyGems requests and covers registration and reruns, repository/workflow/environment matching, authentication and MFA, API failures, configuration loading, and Bake argument parsing.

  • Full test suite on Ruby 4.0.5: 192 tests, 748 assertions, 100% line coverage; covered:validate passes.
  • RuboCop for all changed Ruby and Markdown files.
  • Documentation coverage for lib: 41/41 public definitions.
  • Manual validation: the maintainer successfully registered socketry/fiber-profiler on RubyGems using this task, with release-publish.yaml and the rubygems environment.

Signed-off-by: Samuel Williams <samuel.williams@shopify.com>
@samuel-williams-shopify
samuel-williams-shopify merged commit 7600c0f into main Sep 27, 2026
25 checks passed
@samuel-williams-shopify
samuel-williams-shopify deleted the setup-trusted-publisher branch September 27, 2026 10:36
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