@@ -12,33 +12,22 @@ jobs:
1212 runs-on : ubuntu-latest
1313 container : registry.fedoraproject.org/fedora:42
1414 steps :
15- - name : Update go.mod and open a PR
16- env :
17- GH_TOKEN : ${{ secrets.SCHUTZBOT_GITHUB_ACCESS_TOKEN }}
18- run : |
19- # Install deps
20- set -x
21- sudo dnf -y install git gh golang gpgme-devel btrfs-progs-devel krb5-devel
22- # Checkout the project
23- git clone --depth 1 https://github.com/osbuild/images
24- cd images/
25- # Install and run gobump
26- echo -e '## gobump output:\n\n```' > github_pr_body.txt
27- go run github.com/lzap/gobump@latest -exec "go build ./..." -exec "go test ./..." 2>&1 | tee -a github_pr_body.txt
28- echo -e '\n```' >> github_pr_body.txt
29- ./tools/prepare-source.sh
30- # Make a PR when needed
31- if git diff --exit-code; then echo "No changes"; exit 0; fi
32- git config user.name "schutzbot"
33- git config user.email "schutzbot@gmail.com"
34- branch="schutz-gobump-$(date -I)"
35- git checkout -b "${branch}"
36- git add -A
37- git commit -m "build(deps): Update dependencies via gobump"
38- git push -f "https://$GH_TOKEN@github.com/schutzbot/images.git"
39- gh pr create \
40- -t "Update dependencies $(date -I)" \
41- -F "github_pr_body.txt" \
42- --repo "osbuild/images" \
43- --base "main" \
44- --head "schutzbot:${branch}"
15+ - name : Set up the environment
16+ run : " sudo dnf -y install git gh openssl gcc gpgme-devel btrfs-progs-devel krb5-devel"
17+
18+ - name : Checkout repository
19+ uses : actions/checkout@v4
20+
21+ - name : Run gobump-deps action
22+ uses : lzap/gobump@main
23+ with :
24+ # keep in sync with go.mod and prepare-source.sh
25+ go_version : " 1.22.9"
26+ cgo_enabled : 1
27+ token : ${{ secrets.SCHUTZBOT_GITHUB_ACCESS_TOKEN }}
28+ exec : " go build -buildvcs=false ./..."
29+ exec2 : " go test -buildvcs=false ./..."
30+ labels : " gobump"
31+ tidy : false
32+ exec_pr : " ./tools/prepare-source.sh"
33+ pr : true
0 commit comments