diff --git a/.github/workflows/check-renovatebot-config.yml b/.github/workflows/check-renovatebot-config.yml index c56bb36..6ff501c 100644 --- a/.github/workflows/check-renovatebot-config.yml +++ b/.github/workflows/check-renovatebot-config.yml @@ -8,13 +8,6 @@ on: jobs: validate: - name: Validate renovatebot config - runs-on: ubuntu-24.04 - steps: - - name: Checkout - uses: actions/checkout@v4 - - - name: Validate - uses: suzuki-shunsuke/github-action-renovate-config-validator@v0.1.3 - with: - config_file_path: renovatebot/jore4-default-preset.json5 + uses: HSLdevcom/jore4-tools/.github/workflows/shared-check-renovatebot-config.yml@shared-check-renovatebot-config-v1 + with: + config_file_path: renovatebot/jore4-default-preset.json5 diff --git a/.github/workflows/shared-check-renovatebot-config.yml b/.github/workflows/shared-check-renovatebot-config.yml new file mode 100644 index 0000000..189742c --- /dev/null +++ b/.github/workflows/shared-check-renovatebot-config.yml @@ -0,0 +1,29 @@ +name: Shared check renovatebot config + +on: + workflow_call: + inputs: + config_file_path: + description: Path to the Renovatebot config file to validate + type: string + required: true + checkout_submodules: + description: Whether to checkout submodules + type: string + required: false + default: "false" + +jobs: + validate: + name: Validate renovatebot config + runs-on: ubuntu-24.04 + steps: + - name: Checkout + uses: actions/checkout@v5 + with: + submodules: ${{ inputs.checkout_submodules }} + + - name: Validate config + uses: suzuki-shunsuke/github-action-renovate-config-validator@c22827f47f4f4a5364bdba19e1fe36907ef1318e # v1.1.1 + with: + config_file_path: ${{ inputs.config_file_path }} diff --git a/README.md b/README.md index 54ed086..dbb934e 100644 --- a/README.md +++ b/README.md @@ -294,10 +294,11 @@ onboarding flow ends. Example: ``` -- name: Validate - uses: suzuki-shunsuke/github-action-renovate-config-validator@v0.1.3 - with: - config_file_path: .github/renovate.json5 +jobs: + validate: + uses: HSLdevcom/jore4-tools/.github/workflows/shared-check-renovatebot-config.yml@shared-check-renovatebot-config-v1 + with: + config_file_path: renovatebot/jore4-default-preset.json5 ``` To see a bit more in detail how the renovatebot rules work, check the comments within the