diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2328d0e3..46717c2b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -24,7 +24,17 @@ repos: args: ["--config-file", "pyproject.toml"] additional_dependencies: - types-PyYAML +- repo: https://github.com/compilerla/conventional-pre-commit + rev: v3.2.0 + hooks: + - id: conventional-pre-commit + stages: [commit-msg] + args: [--strict] - repo: https://github.com/igorshubovych/markdownlint-cli rev: v0.39.0 hooks: - id: markdownlint +- repo: https://github.com/renovatebot/pre-commit-hooks + rev: 37.353.0 + hooks: + - id: renovate-config-validator diff --git a/README.md b/README.md index 681367fd..14901235 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ [![Continuous Integration Status](https://github.com/canonical/glauth-k8s-operator/actions/workflows/on_push.yaml/badge.svg?branch=main)](https://github.com/canonical/glauth-k8s-operator/actions?query=branch%3Amain) [![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit) +[![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-%23FE5196.svg)](https://conventionalcommits.org) This repository holds the Juju Kubernetes charmed operator for [GLAuth](https://github.com/glauth/glauth), an open-sourced LDAP server. diff --git a/renovate.json b/renovate.json new file mode 100644 index 00000000..3b36b6be --- /dev/null +++ b/renovate.json @@ -0,0 +1,75 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + "config:base", + ":disableDependencyDashboard", + ":automergeDigest", + ":automergePatch", + ":automergeMinor", + ":rebaseStalePrs", + ":semanticCommits", + ":semanticCommitScope(deps)", + "helpers:pinGitHubActionDigests", + ":enablePreCommit" + ], + "automergeType": "pr", + "rebaseWhen": "behind-base-branch", + "packageRules": [ + { + "groupName": "github actions", + "matchManagers": ["github-actions"], + "matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"], + "automerge": true, + "schedule": ["at any time"], + "additionalBranchPrefix": "auto-" + }, + { + "groupName": "operator pip deps", + "matchManagers": ["pip_requirements"], + "matchUpdateTypes": ["minor", "patch", "pin", "digest"], + "schedule": ["at any time"], + "prPriority": 5, + "additionalBranchPrefix": "auto-" + }, + { + "groupName": "operator pip deps", + "matchManagers": ["pip_requirements"], + "matchUpdateTypes": ["major"], + "schedule": ["at any time"], + "prPriority": 5 + }, + { + "groupName": "testing pip deps", + "matchManagers": ["pip_requirements"], + "matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"], + "automerge": true, + "schedule": ["at any time"], + "prPriority": 4, + "additionalBranchPrefix": "auto-" + }, + { + "groupName": "testing deps", + "matchFiles": ["tox.ini"], + "matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"], + "automerge": true, + "schedule": ["on monday"], + "additionalBranchPrefix": "auto-" + }, + { + "groupName": "renovate packages", + "matchSourceUrlPrefixes": ["https://github.com/renovatebot/"], + "matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"], + "automerge": true, + "schedule": ["at any time"], + "additionalBranchPrefix": "auto-" + }, + { + "groupName": "pre-commit hooks", + "matchManagers": ["pre-commit"], + "matchUpdateTypes": ["major", "minor", "patch", "pin", "digest"], + "automerge": true, + "schedule": ["at any time"], + "additionalBranchPrefix": "auto-" + } + ] +} diff --git a/tox.ini b/tox.ini index 84563903..41cd3619 100644 --- a/tox.ini +++ b/tox.ini @@ -29,8 +29,7 @@ deps = mypy types-PyYAML commands = - pre-commit install - pre-commit autoupdate + pre-commit install -t commit-msg [testenv:fmt] description = Apply coding style standards to code