Skip to content

Commit

Permalink
CI updates
Browse files Browse the repository at this point in the history
This is done by the automated script named upgrade-c2cciutils-to-1.7
  • Loading branch information
sbrunner committed Oct 13, 2023
1 parent 25f55c8 commit 9801703
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 42 deletions.
10 changes: 7 additions & 3 deletions .github/renovate.json5
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,12 @@
},
'pre-commit': { enabled: true },
regexManagers: [
/** Do updates on pre-commit additional dependencies */
{
fileMatch: ['^\\.pre-commit-config\\.yaml$'],
fileMatch: ['^\\.pre\\-commit\\-config\\.yaml$'],
matchStrings: [" +- '?(?<depName>[^' @=]+)(@|==)(?<currentValue>[^' @=]+)'? # (?<datasource>.+)"],
},
/** Do update on the schema present in the ci/config.yaml */
{
fileMatch: ['^ci/config\\.yaml$'],
matchStrings: [
Expand All @@ -30,22 +32,24 @@
},
],
packageRules: [
/** Automerge the patch, the minor and the dev dependency */
/** Auto merge the dev dependency update */
{
matchDepTypes: ['devDependencies'],
automerge: true,
},
/** Group the patch and the minor */
/** Group and auto merge the patch updates */
{
matchUpdateTypes: ['patch'],
groupName: 'all patch versions',
automerge: true,
},
/** Group and auto merge the minor updates */
{
matchUpdateTypes: ['minor'],
groupName: 'all minor versions',
automerge: true,
},
/** Support the 4 parts of shellcheck-py version with a v prefix */
{
matchPackageNames: ['shellcheck-py/shellcheck-py'],
versioning: 'regex:^v(?<major>\\d+)\\.(?<minor>\\d+)\\.(?<patch>\\d+)\\.(?<build>\\d+)$',
Expand Down
13 changes: 0 additions & 13 deletions .github/run-changelog.mjs

This file was deleted.

25 changes: 25 additions & 0 deletions .github/workflows/dependency-auto-review.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Auto reviews updates

on:
pull_request:
types:
- opened
- reopened

jobs:
auto-merge:
name: Auto reviews updates
runs-on: ubuntu-22.04
timeout-minutes: 5

steps:
- uses: actions/github-script@v6
with:
script: |-
github.rest.pulls.createReview({
owner: context.repo.owner,
repo: context.repo.repo,
pull_number: context.payload.pull_request.number,
event: 'APPROVE',
})
if: github.event.pull_request.user.login == 'renovate[bot]'
22 changes: 0 additions & 22 deletions .github/workflows/dependency-update-review.yaml

This file was deleted.

16 changes: 12 additions & 4 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,17 @@ jobs:
run: c2cciutils-publish
if: matrix.helm == 'latest'

- name: Install octokit/action
run: npm install @octokit/action
- name: Run changelog
run: node .github/run-changelog.mjs
- name: Trigger changelog workflow
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: actions/github-script@v6
with:
script: |-
if (process.env.GITHUB_REF_TYPE == 'tag') {
console.log('Trigger changelog');
await github.rest.repos.createDispatchEvent({
owner: 'camptocamp',
repo: 'helm-mutualize',
event_type: 'changelog',
});
}

0 comments on commit 9801703

Please sign in to comment.