Skip to content

Commit

Permalink
Merge pull request #108 from TheRealArthurDent/style/pre-commit
Browse files Browse the repository at this point in the history
style: pre-commit
  • Loading branch information
TheRealArthurDent authored Oct 23, 2024
2 parents 03a5b8c + 8058626 commit ce2d603
Show file tree
Hide file tree
Showing 3 changed files with 104 additions and 42 deletions.
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ indent_size = 2
[*.{yaml,yml}]
indent_style = space
indent_size = 2

[*.json]
indent_size = 2
21 changes: 19 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,20 +1,37 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
exclude: '.vscode/.*'
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
# renovate: datasource=github-releases depName=pre-commit-hooks packageName=pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: no-commit-to-branch
args: [--branch, main]
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-json
- id: pretty-format-json
args:
- "--autofix"
- id: check-yaml
- id: check-added-large-files

- repo: https://github.com/renovatebot/pre-commit-hooks
rev: 38.110.1
# renovate: datasource=github-releases depName=renovate-config-validator packageName=renovatebot/pre-commit-hooks
rev: 38.129.2
hooks:
- id: renovate-config-validator
language_version: 20.18.0

- repo: https://github.com/rhysd/actionlint
# renovate: datasource=github-releases depName=actionlint packageName=rhysd/actionlint
rev: v1.7.3
hooks:
- id: actionlint-docker

- repo: https://github.com/igorshubovych/markdownlint-cli
# renovate: datasource=github-releases depName=markdownlint packageName=igorshubovych/markdownlint-cli
rev: v0.42.0
hooks:
- id: markdownlint-docker
122 changes: 82 additions & 40 deletions renovate.json
Original file line number Diff line number Diff line change
@@ -1,42 +1,84 @@
{
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"reviewers": [
"TheRealArthurDent"
],
"packageRules": [
{
"description": "Auto merge all minor and patch updates to github-actions, pip_requirements and pyenv. Do it without a PR to reduce noise.",
"groupName": "auto merge",
"matchManagers": [
"github-actions",
"pip_requirements",
"pyenv"
],
"matchUpdateTypes": [
"minor",
"patch",
"pin",
"digest"
],
"automerge": true,
"addLabels": [
"auto-merge"
],
"automergeType": "branch"
},
{
"description": "Create PRs for major changes to github-actions, pip_requirements and pyenv.",
"groupName": "MAJOR",
"commitMessagePrefix": "[MAJOR] ",
"matchManagers": [
"github-actions",
"pip_requirements",
"pyenv"
],
"matchUpdateTypes": [
"major"
],
"automerge": false
}
]
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"packageRules": [
{
"addLabels": [
"auto-merge"
],
"automerge": true,
"automergeType": "branch",
"description": "Auto merge all minor and patch updates to github-actions, pip_requirements and pyenv. Do it without a PR to reduce noise.",
"groupName": "auto merge",
"matchManagers": [
"github-actions",
"pip_requirements",
"pyenv"
],
"matchUpdateTypes": [
"minor",
"patch",
"pin",
"digest"
]
},
{
"automerge": false,
"commitMessagePrefix": "[MAJOR] ",
"description": "Create PRs for major changes to github-actions, pip_requirements and pyenv.",
"groupName": "MAJOR",
"matchManagers": [
"github-actions",
"pip_requirements",
"pyenv"
],
"matchUpdateTypes": [
"major"
]
},
{
"addLabels": [
"auto-merge"
],
"automerge": true,
"automergeType": "branch",
"description": "Auto merge all minor and patch updates to pre-commit actions. Do it without a PR to reduce noise.",
"groupName": "pre-commit",
"matchDatasources": [
"github-releases"
],
"matchManagers": [
"regex"
],
"matchUpdateTypes": [
"minor",
"patch",
"pin",
"digest"
],
"schedule": [
"before 5am on Tuesday"
]
},
{
"automerge": false,
"commitMessagePrefix": "[MAJOR] ",
"description": "Create PRs for major changes to pre-commit actions.",
"groupName": "pre-commit MAJOR",
"matchDatasources": [
"github-releases"
],
"matchManagers": [
"regex"
],
"matchUpdateTypes": [
"major"
],
"schedule": [
"before 5am on Tuesday"
]
}
],
"reviewers": [
"TheRealArthurDent"
]
}

0 comments on commit ce2d603

Please sign in to comment.