Commit Graph

27 Commits

Author SHA1 Message Date
Jamie Tanna df7a014c91 refactor: generate the list of templatable fields
As part of follow-up changes, we need a list of fields that could be
used in templates as part of a linting rule.

To avoid the `tools` directory importing from `lib`, we can make sure
that we generate the list of fields.

Co-authored-by: Claude Opus 5 <jamie.tanna+claude-code@mend.io>
2026-08-07 14:28:32 +01:00
Sebastian Poxhofer 2dbfd85506 refactor(linters): enable node/no-sync and migrate to async calls (#44693)
* ci(linter): add renovate/no-sync-io rule

Flags calls to a fixed list of Node.js sync I/O APIs (readFileSync,
writeFileSync, mkdirSync, rmSync, readdirSync, statSync, existsSync,
copyFileSync, execSync, spawnSync, execFileSync) in tools/** and
**/*.spec.ts only; production lib code is not targeted.

Set to "warn" instead of "error": the repo has 40 pre-existing
violations, exceeding the agreed fix threshold of 30, so violations
are left in place for follow-up rather than mass-fixed here.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* ci(linter): enforce renovate/no-sync-io at error

Promote the rule from warn to error now that the codebase has been
migrated off synchronous I/O in tools/ and spec files.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* refactor(tools): migrate synchronous fs calls to async equivalents

Replace *Sync fs calls with their async/promise-based counterparts in
tools/ scripts (generate-imports, check runner, utils, cwdchanged hook)
now that renovate/no-sync-io is enforced at error there.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* test: migrate synchronous fs calls in specs to async equivalents

Replace *Sync fs calls (readdirSync, writeFileSync, existsSync, etc.)
with their async/promise-based counterparts across affected spec
files, making the enclosing it()/module-scope initializers async as
needed, to satisfy renovate/no-sync-io now enforced at error.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* ci(linter): replace custom no-sync-io rule with built-in node/no-sync

The oxc built-in covers a superset of the custom fixed-name list.
Migrate the additionally flagged sites: async glob in test-shards,
async execa in prepare-deps, promisified gzip/generateKeyPair in
rpm/hex specs, and rename the misleading execSync mock alias
(it mocks the async rawExec).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-20 14:28:26 +00:00
Jamie Tanna 8b7f2a1b23 refactor: generate all global config options' defaults (#43380)
As part of future changes, we'll use this generated list to refactor
`GlobalConfig.get` to always return a configuration option's default
value.

We can add a generated set of defaults for these global options to make
this easier.

To avoid import cycles, we can make sure that we create a stub import
(which will then be overwritten).

Co-authored-by: Claude Sonnet 4.6 <jamie.tanna+claude-code@mend.io>
2026-05-15 15:41:25 +00:00
Felipe Santos e9e8083223 feat(config-validator): optimize imports to improve speed by 5x (#43048)
Optimize config-validator
2026-05-04 08:48:32 +00:00
Sergei Zharinov a67a96eab5 refactor(lint): Switch to Oxlint (#42384)
* refactor(lint): Switch to Oxlint

* Update .oxlintrc.json

* Fix CI

---------

Co-authored-by: Jamie Tanna <jamie.tanna@mend.io>
2026-04-07 14:42:23 +00:00
Sergei Zharinov 69fedefeed refactor(tools): reduce noise in generate-imports script (#40186)
* base: pile foundation

* refactor(tools): reduce noise in generate-imports script
2026-01-28 12:41:15 +00:00
renovate[bot] 91f10ff88f chore(deps): update linters (main) (#38166)
* chore(deps): update linters

| datasource | package           | from   | to     |
| ---------- | ----------------- | ------ | ------ |
| npm        | @eslint/js        | 9.35.0 | 9.37.0 |
| npm        | eslint            | 9.35.0 | 9.37.0 |
| npm        | typescript-eslint | 8.43.0 | 8.45.0 |

* chore: fix linting issue

* fixup merge problem

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: secustor <sebastian@poxhofer.at>
Co-authored-by: Sebastian Poxhofer <secustor@users.noreply.github.com>
2025-10-28 12:54:27 +00:00
RahulGautamSingh 3ed7f23be6 feat(config/options): allow all managers as parents of managerFilePatterns (#36471) 2025-06-13 05:25:41 +00:00
renovate[bot] eb8c08079e chore(deps): update typescript-eslint monorepo to v8 (major) (#30750)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2024-08-14 10:33:02 +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
RahulGautamSingh 08c0969913 refactor: replace hasha.fromStream with new fn hashStream (#25046) 2023-10-20 07:49:09 +00:00
RahulGautamSingh 9dc51d03c4 refactor(managers): move regex in custom folder (#23715) 2023-08-06 11:00:47 +00:00
Michael Kriese df583b6799 fix(manager): sort file order for hashes (#21948) 2023-05-03 07:59:50 +00:00
renovate[bot] 58aa841d69 build(deps): update dependency minimatch to v9 (#21923)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2023-05-02 13:00:40 +00:00
renovate[bot] fa36011e45 chore(deps): update dependency glob to v10 (#21865)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2023-05-02 09:52:28 +00:00
Michael Kriese c00732f262 chore: replace shelljs (#21870) 2023-04-28 12:17:48 +00:00
Jamie Magee 176282e65f chore: use node: protocol imports (#21181) 2023-03-28 21:05:36 +00:00
Michael Kriese 8270d5512d refactor: fix lint issues (#16779)
* refactor: fix lint issues

* Update lib/renovate.ts

* chore: revert toplevel await for ts
2022-07-26 08:32:12 +00:00
Gabriel-Ladzaretti 974fa7b2a7 refactor(versioning/distro-info): for future use in debian and ubuntu versioning (#14880)
* refactor(tools/distro-info): for later use in ubuntu and debian versioning

distro-info refactor

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

styling

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

distro-info refactor

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

styling

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

use https://debian.pages.debian.net/distro-info-data/ubuntu.csv as distro info data

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

cr changes and migrated from mjs to ts

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

added a crude way to prevent writing corrupted data

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

lint fixes

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

cr changes and migrated from mjs to ts

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

cr changes

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

dynamically check if stable/released.

22.04 release for example

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

fixed JSON order

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

removed ts.ignore

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

cr changes

* refactor(tools/distro-info): for later use in ubuntu and debian versioning

cr changes

Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2022-04-09 14:38:06 +03:00
RahulGautamSingh edfbe81da7 refactor: add manager fingerprinting (#14671)
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2022-04-06 14:28:48 +00:00
RahulGautamSingh 4f65b57225 refactor: refactor static regex out of for loops (#13065) 2021-12-29 07:26:13 +01:00
RahulGautamSingh 91f067b39f fix: refactor regex to use re2 part3 (#12283)
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2021-10-27 14:37:11 +00:00
Sergei Zharinov a9de944eb7 fix(util): Leverage "emojibase" library for shortcode conversions (#9785)
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
2021-06-01 19:19:38 +00:00
Michael Kriese 825a946468 build: convert ts to esm (#9887)
Co-authored-by: Michael Kriese <michael.kriese@visualon.de>
Co-authored-by: Rhys Arkins <rhys@arkins.net>
2021-05-07 15:46:25 +00:00
Michael Kriese 20e18b6437 feat(internal): generate dynamic manager imports (#5818) 2020-04-06 19:38:20 +02:00
Michael Kriese ae3d71387e feat(internal): generate dynamic datasource imports (#5500) 2020-03-24 07:17:59 +01:00