Просмотр исходного кода

feat: auto-update dependencies

Signed-off-by: Moritz Johner <beller.moritz@googlemail.com>
Moritz Johner 3 лет назад
Родитель
Сommit
b682a64cc1
1 измененных файлов с 33 добавлено и 0 удалено
  1. 33 0
      .github/workflows/update-deps.yml

+ 33 - 0
.github/workflows/update-deps.yml

@@ -0,0 +1,33 @@
+name: "Update dependencies"
+on:
+  push:
+    branches:
+      - mj-auto-update-deps
+
+  schedule:
+    # Sunday, 1PM UTC
+  - cron: "0 13 * * 0"
+
+jobs:
+  stale:
+    runs-on: ubuntu-latest
+    steps:
+    - uses: actions/checkout@v2
+    - name: Setup Go
+      uses: actions/setup-go@v3
+      with:
+        go-version: "1.19"
+    - name: create pull request
+      run: |
+        git config --global user.email "ExternalSecretsOperator@users.noreply.github.com"
+        git config --global user.name "External Secrets Operator"
+        BRANCH=update-deps-$(date "+%s")
+        touch example.foo
+        # make update-deps
+        git checkout -b $BRANCH
+        git add -A
+        git commit -m "update dependencies" -s
+        git push origin $BRANCH
+        gh pr create -B main -H ${BRANCH}- --title 'chore: update dependencies' --body 'Created by Github action'
+      env:
+          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}