canary 向けバージョン bump ワークフローを workflow_dispatch で手動実行できるようにする#5867
canary 向けバージョン bump ワークフローを workflow_dispatch で手動実行できるようにする#5867TinyKitten merged 4 commits intodevfrom
Conversation
📝 WalkthroughWalkthrough
Changes
Sequence Diagram(s)sequenceDiagram
participant User as 手動トリガー
participant GitHub as GitHub Actions
participant Repo as リポジトリ / PR
User->>GitHub: workflow_dispatch (inputs.pr_number, inputs.head_ref)
GitHub->>Repo: checkout (use inputs if PR context absent)
GitHub->>Repo: determine PR metadata (use pr context or inputs)
GitHub->>Repo: create/update PR on generated branch
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/bump_version_on_canary_pr.yml:
- Line 8: Add required workflow_dispatch inputs and make every use of
github.event.pull_request.* resilient by falling back to those inputs when the
event is a manual dispatch: define inputs such as pr_number, head_ref, base_ref,
head_sha, and sender_login under workflow_dispatch, then update each reference
(all occurrences of github.event.pull_request.number, .head.ref, .base.ref,
.head.sha, .user.login, etc.) to use a conditional/fallback expression that
prefers github.event.pull_request.* but falls back to the corresponding input
(e.g., use an expression that returns github.event.pull_request.number when
present else inputs.pr_number), ensuring all places that currently read
github.event.pull_request.* will work for both pull_request events and manual
workflow_dispatch runs.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: c79ebdc6-28c3-42ec-9a4b-3328e70d51cf
📒 Files selected for processing (1)
.github/workflows/bump_version_on_canary_pr.yml
…フォールバックを設定して手動実行でもジョブが完走するようにする
Fixes Applied SuccessfullyFixed 1 file based on 1 unresolved CodeRabbit review comment. Files modified:
Commit: The latest autofix changes are on the |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.github/workflows/bump_version_on_canary_pr.yml (1)
30-34: 条件式内の文字列クォートをダブルクォートに統一してください。機能影響はありませんが、このリポジトリのYAML運用ルールに合わせて統一した方が保守しやすいです。
差分案
( - github.event_name == 'pull_request' && + github.event_name == "pull_request" && github.event.pull_request.head.repo.full_name == github.repository && - !contains(github.event.pull_request.labels.*.name, 'skip-version-bump') - ) || github.event_name == 'workflow_dispatch' + !contains(github.event.pull_request.labels.*.name, "skip-version-bump") + ) || github.event_name == "workflow_dispatch"Based on learnings: In YAML workflow files under .github/workflows, enforce double-quote usage for strings (e.g., actions inputs, env values).
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In @.github/workflows/bump_version_on_canary_pr.yml around lines 30 - 34, The conditional expression uses single-quoted strings; update them to double-quoted strings so the condition normalizes with the repo's YAML rule: change 'pull_request', 'skip-version-bump', and 'workflow_dispatch' to use double quotes in the condition that references github.event_name, github.event.pull_request.head.repo.full_name == github.repository, and contains(github.event.pull_request.labels.*.name, ...).
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In @.github/workflows/bump_version_on_canary_pr.yml:
- Around line 30-34: The conditional expression uses single-quoted strings;
update them to double-quoted strings so the condition normalizes with the repo's
YAML rule: change 'pull_request', 'skip-version-bump', and 'workflow_dispatch'
to use double quotes in the condition that references github.event_name,
github.event.pull_request.head.repo.full_name == github.repository, and
contains(github.event.pull_request.labels.*.name, ...).
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: e9ca7f0e-3948-413c-aa6b-e0e4bd5ead85
📒 Files selected for processing (1)
.github/workflows/bump_version_on_canary_pr.yml
Nitpick fix reverted
理由: GitHub Actions の式言語( CodeRabbit の learning「.github/workflows 配下では文字列はダブルクォート」は YAML スカラー値(actions の input 値や env 値など)に対するルールで、Actions 式言語には適用できません。今回の指摘箇所は対象外と判断します。 The latest changes are on the |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
概要
canary 向けバージョン bump ワークフロー (
bump_version_on_canary_pr.yml) にworkflow_dispatchトリガーを追加し、GitHub Actions の UI から手動で実行できるようにする。変更の種類
変更内容
.github/workflows/bump_version_on_canary_pr.ymlのon:にworkflow_dispatch:を追加。canary 向け PR が opened された時の自動実行に加えて、Actions タブから任意のタイミングで手動実行できる。テスト
npm run lintが通ることnpm testが通ることnpm run typecheckが通ること関連Issue
スクリーンショット(任意)
Summary by CodeRabbit
リリースノート