From 7782b9a1afaf6d752028c78d19f3cbc00d0b29fc Mon Sep 17 00:00:00 2001 From: fraxken Date: Sat, 24 May 2025 23:27:04 +0200 Subject: [PATCH] chore: update eslint-config to v2.x --- lib/console-printer/index.ts | 2 +- package.json | 2 +- src/configuration/environment/index.ts | 4 ++-- src/configuration/external/adapt.ts | 4 ++-- src/configuration/external/nodesecure/ignore-file.ts | 2 +- src/configuration/external/nodesecure/index.spec.ts | 2 +- src/configuration/external/nodesecure/index.ts | 6 +++--- src/configuration/external/standardize.ts | 1 - src/reporting/reporters/internal/scanner.ts | 2 +- .../reporters/post-pipeline/console/dependency-warnings.ts | 4 ++-- src/reporting/reporters/post-pipeline/console/index.ts | 2 +- src/reporting/reporters/post-pipeline/console/util.ts | 1 + 12 files changed, 16 insertions(+), 16 deletions(-) diff --git a/lib/console-printer/index.ts b/lib/console-printer/index.ts index fe7ac16..a7ded7d 100644 --- a/lib/console-printer/index.ts +++ b/lib/console-printer/index.ts @@ -1,4 +1,4 @@ -// Import Third-party dependencies +// Import Third-party Dependencies import kleur from "kleur"; export type ConsoleMessage = { diff --git a/package.json b/package.json index 76a6e28..f53ecea 100644 --- a/package.json +++ b/package.json @@ -60,7 +60,7 @@ "lint": "eslint ." }, "devDependencies": { - "@openally/config.eslint": "^1.0.0", + "@openally/config.eslint": "^2.1.0", "@openally/config.typescript": "^1.0.3", "@types/lodash.set": "^4.3.9", "@types/node": "^22.3.0", diff --git a/src/configuration/environment/index.ts b/src/configuration/environment/index.ts index 20dafb4..fec505d 100644 --- a/src/configuration/environment/index.ts +++ b/src/configuration/environment/index.ts @@ -1,6 +1,6 @@ // Import Node.js Dependencies -import fs from "fs/promises"; -import path from "path"; +import fs from "node:fs/promises"; +import path from "node:path"; // Import Internal Dependencies import type { ValueOf } from "../../types/index.js"; diff --git a/src/configuration/external/adapt.ts b/src/configuration/external/adapt.ts index 32f8252..c321b69 100644 --- a/src/configuration/external/adapt.ts +++ b/src/configuration/external/adapt.ts @@ -1,6 +1,6 @@ // Import Node.js Dependencies -import { constants, accessSync } from "fs"; -import { resolve } from "path"; +import { constants, accessSync } from "node:fs"; +import { resolve } from "node:path"; // Import Internal Dependencies import { Nsci } from "../standard/index.js"; diff --git a/src/configuration/external/nodesecure/ignore-file.ts b/src/configuration/external/nodesecure/ignore-file.ts index 1cd0016..a58bec9 100644 --- a/src/configuration/external/nodesecure/ignore-file.ts +++ b/src/configuration/external/nodesecure/ignore-file.ts @@ -1,4 +1,4 @@ -// Import Third-party dependencies +// Import Third-party Dependencies import * as JSXray from "@nodesecure/js-x-ray"; import { Ajv } from "ajv"; diff --git a/src/configuration/external/nodesecure/index.spec.ts b/src/configuration/external/nodesecure/index.spec.ts index f07a990..d47f55d 100644 --- a/src/configuration/external/nodesecure/index.spec.ts +++ b/src/configuration/external/nodesecure/index.spec.ts @@ -3,7 +3,7 @@ import assert from "node:assert"; import { describe, it } from "node:test"; import fs from "node:fs/promises"; -// Internal Dependencies +// Import Internal Dependencies import { IgnorePatterns, IgnoreWarningsPatterns } from "./ignore-file.js"; import { getIgnoreFile } from "./index.js"; diff --git a/src/configuration/external/nodesecure/index.ts b/src/configuration/external/nodesecure/index.ts index 7b4d1d6..722b7b5 100644 --- a/src/configuration/external/nodesecure/index.ts +++ b/src/configuration/external/nodesecure/index.ts @@ -1,6 +1,6 @@ -// Node.Js Dependencies -import fs from "fs/promises"; -import { join } from "path"; +// Import Node.js Dependencies +import fs from "node:fs/promises"; +import { join } from "node:path"; // Import Third-party Dependencies import { type RC as NodeSecureRuntimeConfig, read } from "@nodesecure/rc"; diff --git a/src/configuration/external/standardize.ts b/src/configuration/external/standardize.ts index a4a3bff..6b484e2 100644 --- a/src/configuration/external/standardize.ts +++ b/src/configuration/external/standardize.ts @@ -1,5 +1,4 @@ // Import Third-party Dependencies -// Import Third-party Dependencies import type { RC as NodeSecureRuntimeConfig } from "@nodesecure/rc"; // Import Internal Dependencies diff --git a/src/reporting/reporters/internal/scanner.ts b/src/reporting/reporters/internal/scanner.ts index a802bc8..b5d4c01 100644 --- a/src/reporting/reporters/internal/scanner.ts +++ b/src/reporting/reporters/internal/scanner.ts @@ -78,7 +78,7 @@ function reportScannerDependencies(payload: Payload): void { consolePrinter.font .highlight(`${numberOfDeps} ${pluralize("dependencies", numberOfDeps)}`) .bold().message, - consolePrinter.font.standard(`analyzed from`).message, + consolePrinter.font.standard("analyzed from").message, consolePrinter.font.info(payload.rootDependencyName ?? "unknown").message ]) .printWithEmptyLine(); diff --git a/src/reporting/reporters/post-pipeline/console/dependency-warnings.ts b/src/reporting/reporters/post-pipeline/console/dependency-warnings.ts index 9a05ee6..47accda 100644 --- a/src/reporting/reporters/post-pipeline/console/dependency-warnings.ts +++ b/src/reporting/reporters/post-pipeline/console/dependency-warnings.ts @@ -93,7 +93,7 @@ export function reportDependencyWarnings( if (warningsMode === Nsci.warnings.OFF) { consolePrinter.font - .info(`⚠ dependency warnings were skipped`) + .info("⚠ dependency warnings were skipped") .bold() .printWithEmptyLine(); @@ -102,7 +102,7 @@ export function reportDependencyWarnings( if (numberOfDependencyWarnings === 0) { consolePrinter.font - .success(`✓ 0 dependency warnings`) + .success("✓ 0 dependency warnings") .bold() .printWithEmptyLine(); diff --git a/src/reporting/reporters/post-pipeline/console/index.ts b/src/reporting/reporters/post-pipeline/console/index.ts index 9a07620..b0815da 100644 --- a/src/reporting/reporters/post-pipeline/console/index.ts +++ b/src/reporting/reporters/post-pipeline/console/index.ts @@ -1,5 +1,5 @@ // Import Node.js Dependencies -import { performance } from "perf_hooks"; +import { performance } from "node:perf_hooks"; // Import Third-party Dependencies import ms from "pretty-ms"; diff --git a/src/reporting/reporters/post-pipeline/console/util.ts b/src/reporting/reporters/post-pipeline/console/util.ts index 9ec8ad1..a5f4982 100644 --- a/src/reporting/reporters/post-pipeline/console/util.ts +++ b/src/reporting/reporters/post-pipeline/console/util.ts @@ -1,6 +1,7 @@ // Import Third-party Dependencies import { match } from "ts-pattern"; +// Import Internal Dependencies import { type ConsoleMessage, type ConsoleOutput,