From 606f9861381e7f438bfca045e04e42268b3bff9c Mon Sep 17 00:00:00 2001 From: Shuji Aoshima <47586723+aoshimash@users.noreply.github.com> Date: Sat, 9 Aug 2025 02:27:47 +0900 Subject: [PATCH] feat: add Renovate CLI with GitHub Actions workflow - Add .github/renovate.json5 with Go/Docker/GitHub Actions grouping - Add .github/workflows/renovate.yml for weekly Saturday 6:00 JST execution - Support manual trigger via workflow_dispatch - Disable auto-merge, create PRs only Closes #78 Closes #77 --- .github/renovate.json5 | 38 ++++++++++++++++++++++++++++++++++ .github/workflows/renovate.yml | 30 +++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 .github/renovate.json5 create mode 100644 .github/workflows/renovate.yml diff --git a/.github/renovate.json5 b/.github/renovate.json5 new file mode 100644 index 0000000..2d38d96 --- /dev/null +++ b/.github/renovate.json5 @@ -0,0 +1,38 @@ +// .github/renovate.json5 +{ + $schema: "https://docs.renovatebot.com/renovate-schema.json", + extends: [ + "config:recommended", + ":semanticCommits", + ":separateMajorReleases", + ":disableDependencyDashboard", + ], + timezone: "Asia/Tokyo", + automerge: false, + platformAutomerge: false, + labels: ["dependencies", "renovate"], + prCreation: "immediate", + rangeStrategy: "replace", + rebaseWhen: "behind-base-branch", + packageRules: [ + { + matchManagers: ["gomod"], + groupName: "Go modules", + groupSlug: "gomod-all", + separateMultipleMajor: false, + postUpdateOptions: ["gomodTidy"], + }, + { + matchManagers: ["dockerfile"], + groupName: "Docker base images", + groupSlug: "docker-all", + separateMultipleMajor: false, + }, + { + matchManagers: ["github-actions"], + groupName: "GitHub Actions", + groupSlug: "gha-all", + separateMultipleMajor: false, + }, + ], +} diff --git a/.github/workflows/renovate.yml b/.github/workflows/renovate.yml new file mode 100644 index 0000000..4e5e566 --- /dev/null +++ b/.github/workflows/renovate.yml @@ -0,0 +1,30 @@ +# .github/workflows/renovate.yml +name: Renovate (CLI) + +on: + schedule: + # JST 06:00 土曜 = UTC 金曜 21:00 + - cron: "0 21 * * 5" + workflow_dispatch: {} + +permissions: + contents: write + pull-requests: write + +concurrency: + group: renovate + cancel-in-progress: false + +jobs: + renovate: + runs-on: ubuntu-latest + steps: + - name: Run Renovate + uses: renovatebot/github-action@v40.1.12 + with: + token: ${{ secrets.RENOVATE_TOKEN }} + configurationFile: .github/renovate.json5 + env: + RENOVATE_REPOSITORIES: ${{ github.repository }} + RENOVATE_PLATFORM: github + LOG_LEVEL: info