diff --git a/docs/usage/self-hosted-experimental.md b/docs/usage/self-hosted-experimental.md index b9d4409f32a8c9..9004995ddf874b 100644 --- a/docs/usage/self-hosted-experimental.md +++ b/docs/usage/self-hosted-experimental.md @@ -172,3 +172,7 @@ Source: [AWS S3 documentation - Interface BucketEndpointInputConfig](https://doc If set, Renovate will use SQLite as the backend for the package cache. Don't combine with `redisUrl`, Redis would be preferred over SQlite. + +## `RENOVATE_X_SUPPRESS_PRE_COMMIT_WARNING` + +Suppress the pre-commit support warning in PR bodies. diff --git a/lib/modules/manager/pre-commit/index.ts b/lib/modules/manager/pre-commit/index.ts index 914529ed56e665..d492b8174f822c 100644 --- a/lib/modules/manager/pre-commit/index.ts +++ b/lib/modules/manager/pre-commit/index.ts @@ -11,7 +11,10 @@ export const defaultConfig = { commitMessageTopic: 'pre-commit hook {{depName}}', enabled: false, fileMatch: ['(^|/)\\.pre-commit-config\\.ya?ml$'], - prBodyNotes: [ - 'Note: The `pre-commit` manager in Renovate is not supported by the `pre-commit` maintainers or community. Please do not report any problems there, instead [create a Discussion in the Renovate repository](https://github.com/renovatebot/renovate/discussions/new) if you have any questions.', - ], + prBodyNotes: process.env.RENOVATE_X_SUPPRESS_PRE_COMMIT_WARNING + ? /* istanbul ignore next */ + [] + : [ + 'Note: The `pre-commit` manager in Renovate is not supported by the `pre-commit` maintainers or community. Please do not report any problems there, instead [create a Discussion in the Renovate repository](https://github.com/renovatebot/renovate/discussions/new) if you have any questions.', + ], };