fix(build): check out the current commit when this repository tests itself - #136
Open
harada hiroki (hender14) wants to merge 1 commit into
Open
fix(build): check out the current commit when this repository tests itself#136harada hiroki (hender14) wants to merge 1 commit into
harada hiroki (hender14) wants to merge 1 commit into
Conversation
…tself
The self-checkout ref was always SELF_VERSION, so (1) bumping SELF_VERSION turns
CI red until the matching tag exists, and (2) test-build.yml never exercises a
PR's own changes to action-c2a-build{,-win32}. Use github.sha when the caller is
this repository and keep SELF_VERSION for every other caller.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
| ref: ${{ env.SELF_VERSION }} | ||
| ref: ${{ github.repository == 'arkedge/workflows-c2a' && github.sha || env.SELF_VERSION }} | ||
|
|
||
| - uses: ./action-c2a-build-win32 |
There was a problem hiding this comment.
🚫 [actionlint] reported by reviewdog 🐶
could not parse action metadata in "/github/workspace/action-c2a-build-win32": line 7: unexpected key "type" for definition of input "cmake_flags" [action]
There was a problem hiding this comment.
🚫 [actionlint] reported by reviewdog 🐶
could not parse action metadata in "/github/workspace/action-c2a-build": line 7: unexpected key "type" for definition of input "reviewdog_filter_mode" [action]
workflows-c2a/.github/workflows/build.yml
Line 91 in f0324b7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
build.ymlの自己取得の ref を、workflows-c2a自身からの呼び出しのときだけ実行中のコミットにします。外部から呼ばれた場合はSELF_VERSIONのままで、挙動は変わりません。Why
SELF_VERSIONを次の版に更新した時点ではまだタグが無いため、test-build.ymlの自己取得がrefs/tags/vX.Y.Zを解決できず失敗します (bump version to v6.0.3 #135 で発生中)SELF_VERSION(= 最新タグ) のものになるため、action-c2a-build{,-win32}への変更は CI を通っていませんこの 2 つはどちらも「自分自身をテストするときに固定タグを見ている」ことが原因なので、そこだけ実行中のコミットに切り替えます。
補足
同様の条件分岐は
amd/skillsの再利用ワークフローでも使われています (if: github.repository != 'amd/skills')。この PR の
test-buildが緑になれば、PR 自身のコミットのアクションでビルドが通ることの確認になります。