Class: ReleaseCeremony::Publish
- Inherits:
-
Object
- Object
- ReleaseCeremony::Publish
- Extended by:
- Command
- Defined in:
- lib/release_ceremony/publish.rb
Overview
Publishes a prepared, merged release: validates the merge commit, tags it, pushes the tag, watches the tag-triggered release workflow, and confirms the gem appears on RubyGems.
Constant Summary collapse
- USAGE =
'Usage: release_ceremony publish VERSION'- HELP =
<<~TEXT.freeze #{USAGE} Validate and publish the merged release-vVERSION pull request by tagging its merge commit and monitoring the release workflow. TEXT
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(version:, runner:, project: nil) ⇒ Publish
constructor
A new instance of Publish.
Methods included from Command
Constructor Details
Instance Method Details
#call ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/release_ceremony/publish.rb', line 24 def call runner.run('git', 'fetch', '--no-tags', project.remote, project.default_branch) pull_request = merged_pull_request sha = pull_request.sha validate_release_commit!(sha) = tag_state (, sha) print_summary(pull_request, ) confirm! publish_tag(, sha) monitor_release(sha) true end |