Update node-style-text to v2 (#18073)

This commit is contained in:
fisker Cheung authored and GitHub committed 2025-10-14 19:30:07 +08:00
1 parent 0a14c4a72c
commit 3c469a820e
8 files changed
+20 -22

No files matched your search

+2
View File
@@ -11,6 +11,7 @@ import eslintPluginRegexp from "eslint-plugin-regexp";
import eslintPluginSimpleImportSort from "eslint-plugin-simple-import-sort";
import eslintPluginUnicorn from "eslint-plugin-unicorn";
import globals from "globals";
import eslintConfigNodeStyleText from "node-style-text/eslint-config";
import eslintPluginPrettierInternalRules from "./scripts/tools/eslint-plugin-prettier-internal-rules/index.js";
const toPath = (file) => url.fileURLToPath(new URL(file, import.meta.url));
@@ -45,6 +46,7 @@ const configs = [
eslintPluginRegexp.configs["flat/recommended"],
eslintPluginUnicorn.configs["flat/recommended"],
eslintConfigPrettier,
eslintConfigNodeStyleText,
{
languageOptions: {
globals: { ...globals.builtin, ...globals.node },
+1 -1
View File
@@ -159,7 +159,7 @@
"knip": "5.64.2",
"magic-string": "0.30.19",
"nano-spawn": "2.0.0",
"node-style-text": "1.0.0",
"node-style-text": "2.1.1",
"npm-run-all2": "8.0.4",
"prettier": "3.6.2",
"pretty-bytes": "7.1.0",
+1 -3
View File
@@ -171,9 +171,7 @@ async function run() {
}
console.log(
styleText.inverse(
`[${index + 1}/${packagesToBuild.length}] Building package '${packageConfig.packageName}'`,
),
styleText.inverse`[${index + 1}/${packagesToBuild.length}] Building package '${packageConfig.packageName}'`,
);
const startTime = performance.now();
+1 -1
View File
@@ -8,7 +8,7 @@
"enquirer": "2.4.1",
"fast-glob": "3.3.3",
"nano-spawn": "2.0.0",
"node-style-text": "1.0.0",
"node-style-text": "2.1.1",
"outdent": "0.8.0",
"semver": "7.7.3"
},
+3 -5
View File
@@ -57,11 +57,9 @@ export default async function postPublishSteps({ dry, next }) {
console.log(
outdent`
${styleText.yellow.bold(
`The following ${
steps.length === 1 ? "step is" : "steps are"
} optional.`,
)}
${styleText.yellow.bold`The following ${
steps.length === 1 ? "step is" : "steps are"
} optional.`}
${steps.join("\n\n")}
`,
@@ -39,7 +39,7 @@ export default async function showInstructionsAfterNpmPublish({
next,
}) {
if (next) {
console.log(`${styleText.green.bold(`Prettier ${version} published!`)}`);
console.log(`${styleText.green.bold`Prettier ${version} published!`}`);
await waitForEnter();
return;
}
@@ -47,7 +47,7 @@ export default async function showInstructionsAfterNpmPublish({
const releaseUrl = getReleaseUrl(version, previousVersion);
console.log(
outdent`
${styleText.green.bold(`Prettier ${version} published!`)}
${styleText.green.bold`Prettier ${version} published!`}
${styleText.yellow.bold("Some manual steps are necessary.")}
+5 -5
View File
@@ -152,10 +152,10 @@ __metadata:
languageName: node
linkType: hard
"node-style-text@npm:1.0.0":
version: 1.0.0
resolution: "node-style-text@npm:1.0.0"
checksum: 10/98c66d0bb040d648200edcb2ecafec3ed23b5b0b336e9982100b0d1e4b8b8cf0864680d1c07598f7694f9e9de4a54d9d5ac370c7f06f22b31bc8883dcfc6a244
"node-style-text@npm:2.1.1":
version: 2.1.1
resolution: "node-style-text@npm:2.1.1"
checksum: 10/e81069a3819900b5c3176f84e258f30915afe8a2166e52d3f2ebeb29c23bacd5f83e82257189426c66bb4ccb232e592b4feb9f09a617180ab568085f02171b02
languageName: node
linkType: hard
@@ -194,7 +194,7 @@ __metadata:
enquirer: "npm:2.4.1"
fast-glob: "npm:3.3.3"
nano-spawn: "npm:2.0.0"
node-style-text: "npm:1.0.0"
node-style-text: "npm:2.1.1"
outdent: "npm:0.8.0"
semver: "npm:7.7.3"
languageName: unknown
+5 -5
View File
@@ -6729,10 +6729,10 @@ __metadata:
languageName: node
linkType: hard
"node-style-text@npm:1.0.0":
version: 1.0.0
resolution: "node-style-text@npm:1.0.0"
checksum: 10/98c66d0bb040d648200edcb2ecafec3ed23b5b0b336e9982100b0d1e4b8b8cf0864680d1c07598f7694f9e9de4a54d9d5ac370c7f06f22b31bc8883dcfc6a244
"node-style-text@npm:2.1.1":
version: 2.1.1
resolution: "node-style-text@npm:2.1.1"
checksum: 10/e81069a3819900b5c3176f84e258f30915afe8a2166e52d3f2ebeb29c23bacd5f83e82257189426c66bb4ccb232e592b4feb9f09a617180ab568085f02171b02
languageName: node
linkType: hard
@@ -7402,7 +7402,7 @@ __metadata:
minimist: "npm:1.2.8"
n-readlines: "npm:1.0.1"
nano-spawn: "npm:2.0.0"
node-style-text: "npm:1.0.0"
node-style-text: "npm:2.1.1"
npm-run-all2: "npm:8.0.4"
outdent: "npm:0.8.0"
oxc-parser: "npm:0.94.0"