Skip to content

Commit

Permalink
docs(configuration options): rewrite keepUpdatedLabel (#27703)
Browse files Browse the repository at this point in the history
Co-authored-by: Rhys Arkins <rhys@arkins.net>
  • Loading branch information
HonkingGoose and rarkins committed Mar 4, 2024
1 parent 54bca16 commit 4c3f70d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
12 changes: 8 additions & 4 deletions docs/usage/configuration-options.md
Expand Up @@ -2125,12 +2125,16 @@ We recommend that you use the `strict` mode, and enable the `dependencyDashboard

## keepUpdatedLabel

On supported platforms it is possible to add a label to a PR to recreate/rebase it when the branch falls 1 or more commits behind its base branch.
On supported platforms you may add a label to a PR so that Renovate recreates/rebases the PR when the branch falls behind the base branch.
Adding the `keepUpdatedLabel` label to a PR makes Renovate behave as if `rebaseWhen` were set to `behind-base-branch`, but only for the given PR.
The label is not removed from the PR after the rebase is complete, unlike what happens with `rebaseLabel`.
Renovate does _not_ remove the label from the PR after it finishes rebasing.
This is different from the `rebaseLabel` option, where Renovate _removes_ the label from the PR after rebasing.

This can be useful when you have approved certain PRs and want to keep them updated until they are ready to be merged.
The setting `keepUpdatedLabel` is best used in conjunction with `rebaseWhen` set to the values of `never` or `conflicted` that limit rebasing.
`keepUpdatedLabel` can be useful when you have approved certain PRs and want Renovate to keep the PRs up-to-date until you're ready to merge them.
The setting `keepUpdatedLabel` is best used in this scenario:

- By default, you configure `rebaseWhen` to `never` or `conflicted` to reduce rebasing
- Sometimes, you want Renovate to keep specific PRs up-to-date with their base branch (equivalent to `rebaseWhen=behind-base-branch`)

## labels

Expand Down
2 changes: 1 addition & 1 deletion lib/config/options/index.ts
Expand Up @@ -1766,7 +1766,7 @@ const options: RenovateOptions[] = [
{
name: 'keepUpdatedLabel',
description:
'Label to request Renovate bot always rebase to keep branch updated.',
'If set, users can add this label to PRs to request they be kept updated with the base branch.',
type: 'string',
supportedPlatforms: ['azure', 'gitea', 'github', 'gitlab'],
},
Expand Down

0 comments on commit 4c3f70d

Please sign in to comment.