-
Notifications
You must be signed in to change notification settings - Fork 11
42 lines (37 loc) · 1.22 KB
/
cargo-update.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
name: Update Deps
on:
workflow_dispatch:
# Run every Monday
schedule:
- cron: '30 5 * * 1'
jobs:
cargo-update:
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
- name: Cargo update
run: cargo update
- name: Commit changes
id: commit
continue-on-error: true
run: |
git config user.name 'phylum-bot'
git config user.email '[email protected]'
git commit -a -m "Bump dependencies"
git push --force origin HEAD:auto-cargo-update
- name: Create Pull Request
if: ${{ steps.commit.outcome == 'success' }}
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410 # v6.4.1
with:
github-token: ${{ secrets.GH_RELEASE_PAT }}
script: |
github.rest.pulls.create({
owner: context.repo.owner,
repo: context.repo.repo,
head: "auto-cargo-update",
base: context.ref,
title: "Bump dependencies",
body: "Bump dependencies for all SemVer-compatible updates.",
});