Commit Graph

90 Commits

Author SHA1 Message Date
Sebastian Poxhofer df8c4051ff test(core): replace file snapshots with explicit assertions (#45660)
* test(core): replace file snapshots with explicit assertions

* test(core): replace inline snapshots with explicit assertions

* test(core): assert on relevant sections instead of full bodies

* test(core): drop assertions implied by full equality

* test(core): address review feedback

* test(core): use resolves instead of awaiting inside expect
2026-09-04 10:28:55 +00:00
Jamie Tanna 10da664674 chore(config): be explicit about Renovate CLI in prFooter (#44949)
* chore(config): be explicit about `Renovate CLI` in `prFooter`

This was something I should have done in
72968d3726.

* fixup! chore(config): be explicit about `Renovate CLI` in `prFooter`
2026-07-30 12:00:37 +00:00
Sebastian Poxhofer 9717259ffc refactor(oxlint): enable no-else-return and unicorn/no-lonely-if (#44553)
Enable no-else-return (with allowElseIf: false) and unicorn/no-lonely-if
as errors in .oxlintrc.json and fix all 131 pre-existing violations
(91 no-else-return, 40 unicorn/no-lonely-if) across 98 files.

The no-else-return violations were fixed with the oxlint autofix
(iterated to a fixpoint, plus two else-if chains that required
--fix-dangerously) followed by Prettier formatting. One comment dropped
by the autofix in lib/modules/manager/pub/artifacts.ts was restored
manually. The unicorn/no-lonely-if violations were merged by hand,
preserving comments and coverage-ignore hints.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-14 12:11:21 +00:00
Alex Thomae f3492fe1c8 fix(workers/repository): use GlobalConfig for productLinks (#44126)
* fix(workers/repository): use GlobalConfig for productLinks

PR #44098 added productLinks to GlobalConfig.OPTIONS, which moves it into
GlobalConfig and deletes it from the per-repo config. Several readers
were not migrated and now receive undefined from config.productLinks.

Most visibly, setStability and setConfidence build the status check
target_url from config.productLinks?.documentation. With it now empty the
URL becomes scheme-relative (e.g. "key-concepts/minimum-release-age/"),
which GitLab rejects with HTTP 400. That throws in setBranchStatus and
aborts the branch before its merge request is created.

Migrate the remaining readers to GlobalConfig.get('productLinks'),
matching #44098, and drop the now-redundant coerceString calls and
non-null assertions.

* refactor(config): drop productLinks from RenovateSharedConfig

productLinks is globalOnly and is now read via GlobalConfig.get. Leaving
it on the per-repo RenovateSharedConfig let callers read the (always
empty) config.productLinks, which is the footgun this PR fixes. Remove it
from the shared interface so it only exists on RepoGlobalConfig, and the
type now prevents reintroducing config.productLinks.
2026-06-22 07:16:59 +00:00
RahulGautamSingh c116326bfd fix(config-migration): always reset migration info (#43628)
wrap in try/finally so reset is always called
2026-05-27 13:00:04 +00:00
Sebastian Poxhofer 73b90e958b refactor: remove string concetation for production code (#43442)
refactor: prefer templates rather than `+`
2026-05-19 13:31:27 +00:00
Sebastian Poxhofer 0793274b86 refactor: prefer templates rather than + in test files (#43441)
refactor: prefer templates rather than `+`
2026-05-19 09:52:28 +00:00
Felipe Santos 1bbe82400e fix(gerrit): defer change creation to createPr() (#39250)
* fix(gerrit): defer change creation to `createPr()`

Signed-off-by: Felipe Santos <felipe.santos@ericsson.com>

* Refactor hashtags handling

* Add prTitle to all missing commitAndPush()

* Fix gerrit tests

* Add warning when prTitle is set in updatePr

* Remove now useless labels from commitAndPush

* Fix gerrit client coverage

* Fix gerrit scm coverage

* Fix rebase coverage

* Improve TODO about assignees

* Fix formatting

* Fix review comment

* Extract to a pushForReview function

* Fix after #41382

* Fix onboarding

* Cleanup code

* Fix ESLint

* Fix tests

* Restore gitRetry for git.merge

* Fix tests

* Simplify hashtags code

* Delete pendingChangeBranch in pushForReview()

* Fix test name

* Remove unnecessary test comments

* Improve test name again

* Fix another test name

* Delete local branch in Gerrit SCM

* Add test for deleting pending branch

* Add tests for pushForReview()

* Fix test case name

* Improve another test name

* Fix another small test inconsistency

* Fix some code style issues

* Use isUndefined instead

* Fix one small test style issue

---------

Signed-off-by: Felipe Santos <felipe.santos@ericsson.com>
2026-04-28 08:29:26 +00:00
Jamie Tanna 72968d3726 chore: clarify "Mend Renovate" in PRs (#42841)
As part of general work to reinforce the brand link between Mend and
Renovate, we can improve the default PR body footer to clarify this.

This feeds into #29885 and general naming, where we want to keep these
close, while also not being too "in your face".

This is still user-controlled, but provides a more reasonable default.

This also feeds into #26838 and #39305, where we should also remove the
"Bot" from the footer.
2026-04-23 11:33:36 +00:00
Felipe Santos e8a5c70862 feat(config-migration): preserve comments when migrating renovate.json (#38646)
* feat(config-migration): preserve comments when migrating `renovate.json`

* Replace jsonc-parser with jsonc-weaver

* Switch to npm package

Refs https://github.com/felipecrs/jsonc-weaver/commit/7a168e2fdd6959fab9d1ebd6bb5dafc02dbf62ff

* Fix tests

* Add test coverage for fallback

* Fix coverage again

* Fix coverage for real

* Restore line break
2026-03-13 21:53:52 +00:00
RahulGautamSingh da50c75c49 refactor: move onboardingPrTitle to InheritConfig (#41376)
* refactor: move onboardingPrTitle to InheritConfig

* remove unwanted flat clone
2026-02-22 18:32:16 +00:00
Sergei Zharinov 9d857c1f68 refactor(lint): Organize imports with biome (#40966) 2026-02-06 13:40:01 +00:00
Sergei Zharinov 2b0e80b884 feat!: Switch to ESM modules (#40756) 2026-01-29 14:21:41 +00:00
Sergei Zharinov c5b0a74f82 refactor: Remove constructor parameter properties (#40712) 2026-01-27 11:16:26 +00:00
Sergei Zharinov 930cf6633c refactor: Rewrite imports with .ts extensions (#40700)
fix: Additional vi.mock path corrections and prettier formatting
2026-01-26 22:48:17 +00:00
Michael Kriese c641239c19 fix: use stricter types for renovate config (#39594)
* fix: use stricter types for renovate config

* fix: revert changes

* Apply suggestions from code review
2025-11-28 13:16:27 +00:00
RahulGautamSingh 76f911041a refactor: use named exports (#39196)
* use named exports

* fix test

* add missing imnport

* fix prettier
2025-11-10 12:00:35 +00:00
Jamie Tanna ec91e744b1 chore(config-migration): capitalise Renovate (#38985)
* chore(config-migration): capitalise `Renovate`

* fixup! chore(config-migration): capitalise `Renovate`
2025-11-04 20:37:46 +00:00
renovate[bot] b4ed9e65d9 chore(deps): update dependency @vitest/eslint-plugin to v1.3.23 (main) (#38702)
* chore(deps): update dependency @vitest/eslint-plugin to v1.3.23

| datasource | package               | from   | to     |
| ---------- | --------------------- | ------ | ------ |
| npm        | @vitest/eslint-plugin | 1.3.16 | 1.3.23 |

* remove now unnecessary exceptions

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: secustor <sebastian@poxhofer.at>
2025-10-31 07:50:48 +00:00
renovate[bot] 1280fe4dc7 chore(deps): update dependency @vitest/eslint-plugin to v1.3.16 (main) (#38502)
* chore(deps): update dependency @vitest/eslint-plugin to v1.3.16

| datasource | package               | from   | to     |
| ---------- | --------------------- | ------ | ------ |
| npm        | @vitest/eslint-plugin | 1.3.13 | 1.3.16 |

* fix linting errors

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: secustor <sebastian@poxhofer.at>
2025-10-13 09:24:15 +00:00
travisshivers 49db650766 fix(gerrit): pass config labels to commitAndPush (#38288)
* fix(gerrit): pass config labels to commitAndPush

Pass the config labels to commitAndPush so they get properly populated
for gerrit.

This follows from https://github.com/renovatebot/renovate/pull/35900
which added label support for gerrit but didn't properly pass them
along in all places.

* test: fix tests

Fix tests

* test: extend commit test to ensure labels are passed

Extend the commit test to ensure labels are passed

* refactor: add comment indicating labels are needed only for gerrit

Add comment indicating labels are needed only for gerrit.
2025-10-03 07:28:02 +00:00
RahulGautamSingh 0ae1e373d5 fix(config-migration): ignore commitMessageSuffix for prTitle (#37521) 2025-08-14 16:05:08 +00:00
Felipe Santos c4212f7824 refactor: allow to use the rebase label in PR body, issues, or comments (#36374) 2025-07-11 08:01:04 +00:00
Tobias 134adc40fe fix(repository/config-migration): skip prettier formatting if no parser is detected (#36335) 2025-06-05 21:30:19 +00:00
Alex Recuenco de1ff6ec86 feat: Add mjs options to prettier (#33949) 2025-03-27 08:40:41 +00:00
Michael Kriese 19c115c813 test: cleanup (#34785) 2025-03-13 17:52:09 +00:00
Michael Kriese 4f60a8b7fe test: mock git globally (#34783) 2025-03-13 15:48:02 +00:00
Michael Kriese 1644d9cb18 test: migrate more to vitest (#34500) 2025-02-26 15:45:17 +00:00
Trim21 6e5731b554 test: migrate from jest to vitest (#34499) 2025-02-26 14:18:38 +00:00
Michael Kriese 997c23502e test: migrate to vitest (#34475)
Co-authored-by: HonkingGoose <34918129+HonkingGoose@users.noreply.github.com>
2025-02-26 09:35:54 +00:00
RahulGautamSingh cc69e84822 feat(config/migration): migrate package.json config (#33633)
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2025-01-24 16:34:22 +00:00
RahulGautamSingh 66dcb61908 fix(config-migration): skip migration of package.json (#33122) 2024-12-16 06:04:22 +00:00
RahulGautamSingh 499ea9c747 feat(dashboard): on demand config migration (#31129)
Co-authored-by: HonkingGoose <34918129+HonkingGoose@users.noreply.github.com>
Co-authored-by: Rhys Arkins <rhys@arkins.net>
Co-authored-by: Sergei Zharinov <zharinov@users.noreply.github.com>
2024-10-17 12:44:55 +00:00
RahulGautamSingh 300a9987f7 fix(config-migration): prevent diff check (#31443) 2024-09-17 11:27:44 +00:00
Sebastian Poxhofer 3681b2a945 chore: eslint to enforce for typed imports (#30844) 2024-08-19 13:15:27 +00:00
RahulGautamSingh bb6c27faf8 feat(github): convert platformCommit to enum (#29156)
BREAKING CHANGE: platformCommit will be automatically enabled if running as a GitHub app
2024-07-25 15:28:16 +02:00
Aaron Moat 03919bbfef feat(git)!: determine branch modification based on all branch commits (#28225) 2024-07-25 15:28:16 +02:00
RahulGautamSingh 4b502025fe refactor: rename platformOptions -> platformPrOptions (#30173) 2024-07-16 07:33:55 +00:00
Rhys Arkins 654c447e6e feat: mode=silent (#28396) 2024-05-06 11:40:54 +00:00
RahulGautamSingh f8890796bf feat: update labels when config changes (#25340)
Co-authored-by: Rhys Arkins <rhys@arkins.net>
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
Co-authored-by: HonkingGoose <34918129+HonkingGoose@users.noreply.github.com>
2024-03-30 04:49:13 +00:00
Rhys Arkins ab4d04b415 fix(config-migration): fetch raw file from platform, not fs (#27049)
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2024-02-04 13:05:32 +00:00
Rhys Arkins 535c7ae1a1 refactor: fetch raw config from within config migration (#26891) 2024-01-28 13:36:06 +00:00
renovate[bot] 4c2ce97bb4 build(deps): update dependency prettier to v3.2.2 (#26755)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2024-01-21 08:20:41 +00:00
Michael Kriese a03994f757 feat(config-migration): support editorconfig max_line_length (#26513) 2024-01-05 09:40:37 +00:00
renovate[bot] e5cbbaaf09 build(deps): update dependency prettier to v3 (#23627)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Sergei Zharinov <zharinov@users.noreply.github.com>
2023-11-07 17:12:01 +00:00
Sergei Zharinov b69416ce17 refactor(prettier): Force trailing commas (#25631) 2023-11-07 15:50:29 +00:00
Rhys Arkins 59d0149200 fix: Revert "feat: compare all branch authors when deciding if a branch is modified" (#25254) 2023-10-17 13:35:20 +02:00
Alex Kessock c2cb93ce44 feat: compare all branch authors when deciding if a branch is modified (#21558)
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2023-10-17 08:45:53 +00:00
Michael Kriese 84a97a62fa test(perf): improve test speed (#24323) 2023-09-08 11:40:04 +00:00
Michael Kriese f0d676242a fix: better branch code coverage (#24276) 2023-09-07 04:39:39 +00:00