Skip to content

Commit fad2d1e

Browse files
committed
break: rename the pkg to eslint-plugin-n
1 parent e31a6e1 commit fad2d1e

File tree

6 files changed

+27
-27
lines changed

6 files changed

+27
-27
lines changed

.eslintrc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// to make the ci passing.
99
module.exports = {
1010
reportUnusedDisableDirectives: true,
11-
extends: ["eslint:recommended", "plugin:@weiran.zsd/node/recommended", "plugin:eslint-plugin/recommended"],
11+
extends: ["eslint:recommended", "plugin:n/recommended", "plugin:eslint-plugin/recommended"],
1212
env: {
1313
mocha: true,
1414
}

lib/configs/_commons.js

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -57,20 +57,20 @@ module.exports = {
5757
setImmediate: "readonly",
5858
},
5959
commonRules: {
60-
"@weiran.zsd/node/no-deprecated-api": "error",
61-
"@weiran.zsd/node/no-extraneous-import": "error",
62-
"@weiran.zsd/node/no-extraneous-require": "error",
63-
"@weiran.zsd/node/no-exports-assign": "error",
64-
"@weiran.zsd/node/no-missing-import": "error",
65-
"@weiran.zsd/node/no-missing-require": "error",
66-
"@weiran.zsd/node/no-process-exit": "error",
67-
"@weiran.zsd/node/no-unpublished-bin": "error",
68-
"@weiran.zsd/node/no-unpublished-import": "error",
69-
"@weiran.zsd/node/no-unpublished-require": "error",
70-
"@weiran.zsd/node/no-unsupported-features/es-builtins": "error",
71-
"@weiran.zsd/node/no-unsupported-features/es-syntax": "error",
72-
"@weiran.zsd/node/no-unsupported-features/node-builtins": "error",
73-
"@weiran.zsd/node/process-exit-as-throw": "error",
74-
"@weiran.zsd/node/shebang": "error",
60+
"n/no-deprecated-api": "error",
61+
"n/no-extraneous-import": "error",
62+
"n/no-extraneous-require": "error",
63+
"n/no-exports-assign": "error",
64+
"n/no-missing-import": "error",
65+
"n/no-missing-require": "error",
66+
"n/no-process-exit": "error",
67+
"n/no-unpublished-bin": "error",
68+
"n/no-unpublished-import": "error",
69+
"n/no-unpublished-require": "error",
70+
"n/no-unsupported-features/es-builtins": "error",
71+
"n/no-unsupported-features/es-syntax": "error",
72+
"n/no-unsupported-features/node-builtins": "error",
73+
"n/process-exit-as-throw": "error",
74+
"n/shebang": "error",
7575
},
7676
}

lib/configs/recommended-module.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ module.exports = {
1616
ecmaVersion: 2019,
1717
sourceType: "module",
1818
},
19-
plugins: ["@weiran.zsd/node"],
19+
plugins: ["n"],
2020
rules: {
2121
...commonRules,
22-
"@weiran.zsd/node/no-unsupported-features/es-syntax": [
22+
"n/no-unsupported-features/es-syntax": [
2323
"error",
2424
{ ignores: ["modules"] },
2525
],

lib/configs/recommended-script.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ module.exports = {
1616
ecmaVersion: 2019,
1717
sourceType: "script",
1818
},
19-
plugins: ["@weiran.zsd/node"],
19+
plugins: ["n"],
2020
rules: {
2121
...commonRules,
22-
"@weiran.zsd/node/no-unsupported-features/es-syntax": ["error", { ignores: [] }],
22+
"n/no-unsupported-features/es-syntax": ["error", { ignores: [] }],
2323
},
2424
}

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "@weiran.zsd/eslint-plugin-node",
2+
"name": "eslint-plugin-n",
33
"version": "13.0.1",
44
"description": "Additional ESLint's rules for Node.js",
55
"engines": {
@@ -26,7 +26,7 @@
2626
"codecov": "^3.3.0",
2727
"eslint": "^8.3.0",
2828
"eslint-plugin-eslint-plugin": "^4.0.1",
29-
"@weiran.zsd/eslint-plugin-node": "file:.",
29+
"eslint-plugin-n": "file:.",
3030
"fast-glob": "^2.2.6",
3131
"globals": "^11.12.0",
3232
"mocha": "^6.1.4",

tests/lib/configs/recommended.js

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ describe("node/recommended config", () => {
1515
beforeEach(() => {
1616
process.chdir(root)
1717
linter = new ESLint({
18-
baseConfig: { extends: "plugin:@weiran.zsd/node/recommended" },
18+
baseConfig: { extends: "plugin:n/recommended" },
1919
useEslintrc: false,
2020
})
2121
})
@@ -78,7 +78,7 @@ describe("node/recommended config", () => {
7878
line: 1,
7979
message: '"foo" is not found.',
8080
nodeType: "Literal",
81-
ruleId: "@weiran.zsd/node/no-missing-import",
81+
ruleId: "n/no-missing-import",
8282
severity: 2,
8383
},
8484
])
@@ -94,7 +94,7 @@ describe("node/recommended config", () => {
9494
beforeEach(() => {
9595
process.chdir(root)
9696
linter = new ESLint({
97-
baseConfig: { extends: "plugin:@weiran.zsd/node/recommended" },
97+
baseConfig: { extends: "plugin:n/recommended" },
9898
useEslintrc: false,
9999
})
100100
})
@@ -118,7 +118,7 @@ describe("node/recommended config", () => {
118118
line: 1,
119119
message: '"foo" is not found.',
120120
nodeType: "Literal",
121-
ruleId: "@weiran.zsd/node/no-missing-import",
121+
ruleId: "n/no-missing-import",
122122
severity: 2,
123123
},
124124
])
@@ -159,7 +159,7 @@ describe("node/recommended config", () => {
159159
line: 1,
160160
message: '"foo" is not found.',
161161
nodeType: "Literal",
162-
ruleId: "@weiran.zsd/node/no-missing-import",
162+
ruleId: "n/no-missing-import",
163163
severity: 2,
164164
},
165165
])

0 commit comments

Comments
 (0)