Skip to content

Commit 41e2491

Browse files
committed
fix: remove only-warn plugin
1 parent fee1111 commit 41e2491

9 files changed

+6
-56
lines changed

spec/test.mts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import { command } from "execa"
22
import { resolve, dirname, join } from "path"
33
import packageJson from "../package.json" with { type: "json" }
4-
import * as gitly from "./gitly.js"
5-
const { download, extract } = gitly
4+
// @ts-ignore
5+
import gitly from "./gitly.js"
6+
const { download, extract } = gitly as typeof import("./gitly.js")
67
import fs from "fs-extra"
78
const { pathExists, ensureDir, remove } = fs
89
import { fileURLToPath } from "url"

src/astro.cts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import type { Linter } from "eslint"
22
import { pluginImportAstroRulesExtra } from "./plugin-import-rules.cjs"
33
import astroPlugin from "eslint-plugin-astro"
4-
import * as onlyWarnPlugin from "eslint-plugin-only-warn"
54
import astroParser from "astro-eslint-parser"
65

76
export const astroConfig: Linter.Config[] = [
@@ -21,7 +20,6 @@ export const astroConfig: Linter.Config[] = [
2120
},
2221
plugins: {
2322
astro: astroPlugin,
24-
"only-warn": onlyWarnPlugin,
2523
},
2624
rules: {
2725
...pluginImportAstroRulesExtra,

src/coffeescript.cts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import { pluginNodeRules } from "./plugin-node-rules.cjs"
22
import { pluginImportRulesExtra } from "./plugin-import-rules.cjs"
33
import type { Linter } from "eslint"
44
import * as eslintPluginCoffee from "eslint-plugin-coffee"
5-
import * as onlyWarnPlugin from "eslint-plugin-only-warn"
65
import * as nodePlugin from "eslint-plugin-node"
76
import * as coffeeParser from "eslint-plugin-coffee/parser"
87

@@ -17,7 +16,6 @@ export const coffeeConfig: Linter.Config = {
1716
plugins: {
1817
coffee: eslintPluginCoffee,
1918
node: nodePlugin,
20-
"only-warn": onlyWarnPlugin,
2119
},
2220
rules: {
2321
...pluginNodeRules,

src/index-strict-react.cts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,3 @@
11
import nonStrictConfig from "./index-react.cjs"
22

3-
// // remove only-warn from javascript
4-
// if (
5-
// nonStrictConfig.plugins !== undefined &&
6-
// nonStrictConfig.plugins[nonStrictConfig.plugins.length - 1] === "only-warn"
7-
// ) {
8-
// nonStrictConfig.plugins.pop()
9-
// }
10-
11-
// // remove only-warn from overrides
12-
// nonStrictConfig.overrides?.forEach((overrides) => {
13-
// if (overrides.plugins !== undefined && overrides.plugins[overrides.plugins.length - 1] === "only-warn") {
14-
// overrides.plugins.pop()
15-
// }
16-
// })
17-
183
export default nonStrictConfig

src/index-strict-solid.cts

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,4 @@
11
import nonStrictConfig from "./index-solid.cjs"
22

3-
// // remove only-warn from javascript
4-
// if (
5-
// nonStrictConfig.plugins !== undefined &&
6-
// nonStrictConfig.plugins[nonStrictConfig.plugins.length - 1] === "only-warn"
7-
// ) {
8-
// nonStrictConfig.plugins.pop()
9-
// }
10-
11-
// // remove only-warn from overrides
12-
// nonStrictConfig.overrides?.forEach((overrides) => {
13-
// if (overrides.plugins !== undefined && overrides.plugins[overrides.plugins.length - 1] === "only-warn") {
14-
// overrides.plugins.pop()
15-
// }
16-
// })
173

184
export default nonStrictConfig

src/index-strict.cts

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,3 @@
11
import nonStrictConfig from "./index.cjs"
22

3-
// // remove only-warn from javascript
4-
// if (
5-
// nonStrictConfig.plugins !== undefined &&
6-
// nonStrictConfig.plugins[nonStrictConfig.plugins.length - 1] === "only-warn"
7-
// ) {
8-
// nonStrictConfig.plugins.pop()
9-
// }
10-
11-
// // remove only-warn from overrides
12-
// nonStrictConfig.overrides?.forEach((overrides) => {
13-
// if (overrides.plugins !== undefined && overrides.plugins[overrides.plugins.length - 1] === "only-warn") {
14-
// overrides.plugins.pop()
15-
// }
16-
// })
17-
183
export default nonStrictConfig

src/javascript.cts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import type { Linter } from "eslint"
55
import * as eslintBabelParser from "@babel/eslint-parser"
66
import * as nodePlugin from "eslint-plugin-node"
77
import * as importPlugin from "eslint-plugin-import"
8-
import * as onlyWarnPlugin from "eslint-plugin-only-warn"
98

109
import js from "@eslint/js"
1110

@@ -33,7 +32,7 @@ export const jsConfig: Linter.Config[] = [
3332
plugins: {
3433
node: nodePlugin,
3534
import: importPlugin,
36-
"only-warn": onlyWarnPlugin,
35+
3736
},
3837
rules: {
3938
...eslintRulesExtra,

src/typescript.cts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import * as typeScriptPlugin from "typescript-eslint"
33
import type { Linter } from "eslint"
44
import * as importPlugin from "eslint-plugin-import"
55
import * as nodePlugin from "eslint-plugin-node"
6-
import * as onlyWarnPlugin from "eslint-plugin-only-warn"
76
import type { GlobifiedEntry } from "globify-gitignore"
87
import makeSynchronous from "make-synchronous"
98
import { eslintRulesExtra } from "./official-eslint-rules.cjs"
@@ -137,7 +136,6 @@ export const tsConfig: Linter.Config = {
137136
plugins: {
138137
node: nodePlugin,
139138
import: importPlugin,
140-
"only-warn": onlyWarnPlugin,
141139
},
142140
rules: {
143141
...javaScriptRules(),

tsconfig.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
// check
1616
"strict": true,
1717
"strictNullChecks": true,
18-
"noUnusedLocals": true,
19-
"noUnusedParameters": true,
18+
"noUnusedLocals": false,
19+
"noUnusedParameters": false,
2020
"noImplicitReturns": true,
2121
"noImplicitAny": true,
2222
"noImplicitThis": true,

0 commit comments

Comments
 (0)