generated from bazel-contrib/rules-template
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
automatic Zig update GH actions workflow
- Loading branch information
Showing
1 changed file
with
24 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
name: Zig Update | ||
|
||
on: | ||
schedule: | ||
- cron: 0 0 * * 1 | ||
workflow_dispatch: | ||
|
||
jobs: | ||
update: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Update | ||
run: | | ||
bazel run //util:update_zig_versions | ||
[ -z "$(git status --porcelain=v1 zig/private/versions.bzl 2>/dev/null)" ] || { | ||
NEW_VERSION="$(grep -m 1 -oP '^\s+"\K\d+\.\d+\.\d+(?=":)' zig/private/versions.bzl)" | ||
git add zig/private/versions.bzl | ||
git commit -m 'update Zig versions' | ||
gh pr create \ | ||
--title "chore: update Zig versions up to $NEW_VERSION" \ | ||
--body "- [ ] Manually update references to the latest Zig version." | ||
} |