aboutsummaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorMichael Tews <michael@tews.dev>2026-03-16 15:28:52 +0100
committerMichael Tews <michael@tews.dev>2026-03-16 15:28:52 +0100
commit2c8f6e7cafbb8d3a5431972a331df683a2d24c4b (patch)
treea9f3ac10b9f2926863ba628802deb7c304c4ee46 /.github
parent95563d33c43d61e7a9b205d502f02846e2afcc45 (diff)
ci: adds update rclone version workflow
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/update-rclone.yml54
1 files changed, 54 insertions, 0 deletions
diff --git a/.github/workflows/update-rclone.yml b/.github/workflows/update-rclone.yml
new file mode 100644
index 0000000..0a7c454
--- /dev/null
+++ b/.github/workflows/update-rclone.yml
@@ -0,0 +1,54 @@
+name: Update rclone dependency
+
+on:
+ schedule:
+ - cron: "0 6 * * *"
+ workflow_dispatch:
+
+permissions:
+ contents: write
+ pull-requests: write
+
+jobs:
+ update-rclone:
+ runs-on: ubuntu-latest
+
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v4
+
+ - name: Setup Go
+ uses: actions/setup-go@v5
+ with:
+ go-version-file: go.mod
+
+ - name: Get latest rclone release
+ id: latest
+ run: |
+ LATEST=$(curl -s https://api.github.com/repos/rclone/rclone/releases/latest | jq -r .tag_name)
+ echo "latest=$LATEST" >> "$GITHUB_OUTPUT"
+
+ - name: Get current rclone version
+ id: current
+ run: |
+ CURRENT=$(go list -m -f '{{.Version}}' github.com/rclone/rclone)
+ echo "current=$CURRENT" >> "$GITHUB_OUTPUT"
+
+ - name: Update dependency
+ if: steps.latest.outputs.latest != steps.current.outputs.current
+ run: |
+ go get github.com/rclone/rclone@${{ steps.latest.outputs.latest }}
+ go mod tidy
+
+ - name: Create Pull Request
+ if: steps.latest.outputs.latest != steps.current.outputs.current
+ uses: peter-evans/create-pull-request@v6
+ with:
+ branch: update-rclone-${{ steps.latest.outputs.latest }}
+ commit-message: "Update rclone to ${{ steps.latest.outputs.latest }}"
+ title: "Update rclone to ${{ steps.latest.outputs.latest }}"
+ body: |
+ Automated dependency update.
+
+ rclone updated from `${{ steps.current.outputs.current }}`
+ to `${{ steps.latest.outputs.latest }}`.