Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: auto merge dependabot #1087

Merged
merged 1 commit into from
Sep 12, 2024
Merged

ci: auto merge dependabot #1087

merged 1 commit into from
Sep 12, 2024

Conversation

herablog
Copy link
Member

細かく取り込めていいんですが、_ぽちぽち大変_なのでauto mergeのワークフロー作りました。

マージ条件(minor, patch)以外はほぼコピペです。
ref: https://docs.github.com/ja/code-security/dependabot/working-with-dependabot/automating-dependabot-with-github-actions#enable-auto-merge-on-a-pull-request

@herablog herablog requested a review from sasaplus1 September 12, 2024 02:36
@herablog herablog self-assigned this Sep 12, 2024
@sasaplus1
Copy link
Member

dependabotとrenovateと両方稼働していてどちらかにまとめた方が良いのかなあと思ってるのですが、両方とも稼働させたままにしますか?

@herablog
Copy link
Member Author

herablog commented Sep 12, 2024

dependabotとrenovateと両方稼働していてどちらかにまとめた方が良いのかなあと思ってるのですが、両方とも稼働させたままにしますか?

その質問くるかなと思ってましたw

ちと併用してみようかなと思ってました〜(とはいえ今の設定だとdependabotのがきそうなので、dependabot試す感じになりそうですが)
最近使ってみたら悪くないんですよね

@sasaplus1
Copy link
Member

なるほど、dependabotお試しは昔したまま最近ためしてないのでいいかもしれないですね。

@herablog
Copy link
Member Author

GitHubの公開リポジトリなので、公式乗っかれるか作戦ですw

Copy link
Member

@sasaplus1 sasaplus1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

Comment on lines +19 to +20
if: steps.metadata.outputs.update-type == 'version-update:semver-minor' || steps.metadata.outputs.update-type == 'version-update:semver-patch'
run: gh pr merge --auto --merge "$PR_URL"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

minorまたはpatchのアップデートであればマージする、なるほど

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

build, test workflow pass 必須でっす

@herablog herablog merged commit ca7185a into main Sep 12, 2024
8 checks passed
@herablog herablog deleted the chore/dependabot-auto-merge branch September 12, 2024 03:02
@sasaplus1
Copy link
Member

あー、PRに対してapprove必要なのでauto approveの仕組みも必要だったかもしれないですね……
https://github.com/dependabot/fetch-metadata?tab=readme-ov-file#auto-approving

@sasaplus1
Copy link
Member

あ、いや、gh pr mergeで自分でマージするから要らないですね

@herablog
Copy link
Member Author

今 +1 必要な設定だったかもしれないですね

ここで試してみてます
#1085

@herablog
Copy link
Member Author

必要そうだぁ〜
https://docs.github.com/ja/code-security/dependabot/working-with-dependabot/automating-dependabot-with-github-actions#approve-a-pull-request

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.

2 participants