Build overhaul: fixed build/tooling issues, bumped to ts5/Node18, cleanup#25
Open
velle wants to merge 18 commits intomapcentia:masterfrom
Open
Build overhaul: fixed build/tooling issues, bumped to ts5/Node18, cleanup#25velle wants to merge 18 commits intomapcentia:masterfrom
velle wants to merge 18 commits intomapcentia:masterfrom
Conversation
- /usr/bin/tsc -> tsc - removed `-b` flag, only applicable for multi-project builds
- npm i -D typescript@^5.4 @types/node@^18 tslib@^2.6 - tsconfig: - "module":"NodeNext" # required from Node 18 - "moduleResolution":"NodeNext" - "target":"ES2020" # Node18 recommends ES2020/ES2022 - "types":["node"] # ensure Node globals; avoid accidental global typings from other @types NodeNext is required from Node v. Still does not pass tsc typecheck: - package code passes - dependencies fails, e.g. legacy oclif
Rewrote test hooks:
- removed NODE_OPTIONS='--loader ts-node/esm', to fix ERR_REQUIRE_CYCLE_MODULE
- split into three hooks: test:nyc, test:plain, test
- renamed hook key `posttest` -> `lint`
Status / known issues:
- npm test passes (but prints warning MODULE_TYPELESS_PACKAGE_JSON)
- login.test.ts is intermittently failing (likely network/server latency).
https://gist.github.com/velle/4f14d47d3c52031439f7affc5aae69b8
- linting is broken, besides printing violations, tslint also prints its own warnings/errors
Changes: - Removed deprecated TSLint, deprecated since 2019 - Added ESLint + @typescript-eslint + plugin-n + Prettier - Added minimal eslint.config.cjs, no style check, only checks *.*ts - Updated/created hooks: `lint` and `lint:fix` Status/known issues: - ESLint is minimal, very relaxed - Still 90 violations (none fixed yet)
`npm version 2025.10.0` is now working again
@oclif/parser, @oclif/plugin-autocomplete, @oclif/plugin-update dotenv, fetch-blob, through2, url-parse
…r":true, this is default behavior since npm11
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Background/motivation: Wanted to do a minor bug fix, but could not run build tools.
First attempted at minimally intrusive fixes, but ended up with a rather big overhaul.
Changes:
NodeNext,ES2020,@types/node)@inquirer/promptsinquirer→ 12.9,nyc→ 17.1)Status:
npm packworksnpm testworks (but test occasionally fails)npm versionworks, will keep package-lock.json and README.md in syncRemaining work
login.test.ts