Skip to content

Commit

Permalink
chore(deps): update linters to v8 (major) (#1353)
Browse files Browse the repository at this point in the history
* chore(deps): update linters to v8

* chore: fix lint

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Cody Olsen <[email protected]>
  • Loading branch information
renovate[bot] and stipsan authored Jan 27, 2025
1 parent c21ab13 commit 3daeca8
Show file tree
Hide file tree
Showing 7 changed files with 96 additions and 103 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,8 @@
"@types/semver": "^7.5.8",
"@types/treeify": "^1.0.3",
"@types/uuid": "^10.0.0",
"@typescript-eslint/eslint-plugin": "^7.18.0",
"@typescript-eslint/parser": "^7.18.0",
"@typescript-eslint/eslint-plugin": "^8.21.0",
"@typescript-eslint/parser": "^8.21.0",
"browserslist-to-esbuild": "2.1.1",
"commitizen": "^4.3.1",
"cpx": "^1.5.0",
Expand Down
185 changes: 88 additions & 97 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/node/check.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ async function checkExports(
}

const esbuildWarnings = esbuildResult.warnings.filter((msg) => {
// eslint-disable-next-line @typescript-eslint/no-unused-expressions
!(msg.detail || msg.text).includes(`does not affect esbuild's own target setting`)
})

Expand Down
2 changes: 1 addition & 1 deletion src/node/core/config/loadConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export async function loadConfig(options: {cwd: string}): Promise<PkgConfigOptio

const {unregister} = globalThis.__DEV__ ? {unregister: () => undefined} : register(esbuildOptions)

// eslint-disable-next-line @typescript-eslint/no-var-requires
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-require-imports
const mod = require(configFile)

unregister()
Expand Down
2 changes: 1 addition & 1 deletion src/node/fileExists.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export function fileExists(filePath: string): boolean {
statSync(filePath)

return true
} catch (_) {
} catch {
return false
}
}
2 changes: 1 addition & 1 deletion src/node/templates/default/template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ export const defaultTemplate: PkgTemplate = async ({cwd, logger, packagePath}) =
gitUrlParse(v)

return true
} catch (err) {
} catch {
return 'invalid git url'
}
},
Expand Down
3 changes: 2 additions & 1 deletion test/env/spawnProject.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export function spawnProject(name: string): Promise<{
return
}

// eslint-disable-next-line @typescript-eslint/no-var-requires
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-require-imports
const pkg = require(path.resolve(tmpPath, 'package.json'))

async function runExec(cmd: string) {
Expand Down Expand Up @@ -85,6 +85,7 @@ export function spawnProject(name: string): Promise<{
readFile: (filePath: string) =>
fs.readFile(path.resolve(tmpPath, filePath)).then((r) => r.toString()),
remove: tmpRemove,
// eslint-disable-next-line @typescript-eslint/no-require-imports
require: (id) => require(path.resolve(tmpPath, id)),
run: (cmd: string) => runExec(`pnpm run ${cmd}`),
})
Expand Down

0 comments on commit 3daeca8

Please sign in to comment.