-
Notifications
You must be signed in to change notification settings - Fork 78
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
CI: add bot to update lockfile on dependabot PRs
- Loading branch information
1 parent
9abcad1
commit 03b455d
Showing
2 changed files
with
39 additions
and
38 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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,39 @@ | ||
name: Update Lockfile Bot | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: | ||
- 'dependabot/**' | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: write | ||
|
||
jobs: | ||
lock: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Install uv | ||
uses: astral-sh/setup-uv@v3 | ||
with: | ||
enable-cache: true | ||
cache-dependency-glob: "uv.lock" | ||
|
||
- name: Set up Python | ||
run: uv python install 3.12 | ||
|
||
- name: Update lockfile | ||
run: | | ||
echo "\`\`\`" > uv_output.md | ||
XDSL_VERSION_OVERRIDE="0+dynamic" make venv &>> uv_output.md | ||
echo "\`\`\`" >> uv_output.md | ||
- name: Commit changes | ||
run: | | ||
git config --global user.name 'github-actions[bot]' | ||
git config --global user.email 'github-actions[bot]@users.noreply.github.com' | ||
git add uv.lock | ||
git commit -m "Update uv lockfile" -F uv_output.md || echo "No changes to commit" | ||
git push |