Skip to content

refactor: mark the workflows triggered by this repository's own events as self - #9

Merged
panicboat merged 2 commits into
mainfrom
refactor/self-workflow-prefix
Oct 25, 2026
Merged

panicboat merged 2 commits into
mainfrom
refactor/self-workflow-prefix

Conversation

@panicboat

Copy link
Copy Markdown
Owner

Summary

このリポジトリ自身のイベントで動く workflow を、接頭辞 self-- で区別します。
あわせて、拡張子を .yaml に、name: を 'Self - ...' に揃えます。

Why

reusable--・internal-- は呼び出し元で区別していますが、このリポジトリ自身の workflow には接頭辞がなく、release--please だけが用途名の接頭辞を持っていました。
同じ「誰が呼ぶか」の軸で揃えると、ファイル名と Actions の画面の両方で 3 種類を見分けられます。

Before / After

  • このリポジトリ自身の workflow のファイル名
    • Before: ci-gatekeeper.yaml・lint-actions.yml・semantic-pull-request.yml・test-scripts.yaml・release--please.yaml・test-shared-workflows{,--nested,--checkout}.yaml
    • After: 先頭に self-- を付け、拡張子を .yaml に揃えます。
  • Actions の画面に出る workflow 名
    • Before: CI Gatekeeper・Lint GitHub Actions など接頭辞なし
    • After: Self - CI Gatekeeper・Self - Lint GitHub Actions など
  • 他のリポジトリから呼ぶ reusable--* と internal--* は変わりません。

Decisions

  • 接頭辞は、用途(ci--・release--)ではなく呼び出し元の軸で self-- にしました。
    • 用途で分けると reusable--・internal-- と基準が混ざり、reusable--release--please と並んだときにどちらが自分用か分かりません。
  • test の fixture(--nested・--checkout)は workflow_call ですが、internal-- ではなく self-- にしました。
    • 呼ぶのはこのリポジトリの test だけで、共通の workflow からは呼ばないためです。
  • ファイル名の接頭辞と name: の接頭辞が対応していることを確かめるテストを足しました。
    • 接頭辞のない workflow を足したときに、test で検出します。
  • refactor なので release は出ません。
    • 他のリポジトリから呼ぶ workflow は変わらないためです。

Impact

  • 利用規約
  • プライバシーポリシー
  • ドキュメント
    • README に self--* の説明を足しました。

Verification

  • VERIFIED: bash scripts/workflows/test.sh で 7 件すべて PASS しました。
  • VERIFIED: 接頭辞のない foo.yml を置くと unknown prefix: foo.yml で、name: を接頭辞なしにすると name mismatch: self--test-scripts.yaml で FAIL することを確かめました。
  • VERIFIED: CI と同じ scripts/*/test.sh・scripts/*/*.test.sh・scripts/kubernetes-hydrate/tests/*.test.sh がすべて通りました。
  • REASONED: ruleset dot-github-main の必須チェックは gatekeeper / CI Gatekeeper などの job の名前で指定されていて、ファイル名と workflow 名は使わないので、変わりません。
  • REASONED: semantic-pull-request は pull_request_target なので、この PR では main にある旧ファイルが動き、merge 後から新しいファイルが動きます。
  • ASSUMED: Actions の実行履歴は、名前を変えたファイルごとに新しい workflow として分かれます。

Relations

🤖 Generated with Claude Code

https://claude.ai/code/session_01AeZS4Kg4R7fZfSSUmmBYXr

…s as self

Signed-off-by: panicboat <panicboat@gmail.com>
Signed-off-by: panicboat <panicboat@gmail.com>
@coderabbitai

coderabbitai Bot commented Oct 25, 2026 •

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4c59c815-1569-4c2d-8dff-6fb7ba9b410a
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@panicboat
panicboat marked this pull request as ready for review October 25, 2026 02:57
@panicboat
panicboat merged commit f3cdedc into main Oct 25, 2026
7 checks passed
@panicboat
panicboat deleted the refactor/self-workflow-prefix branch October 25, 2026 02:57
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