@agilebot/eslint-config 0.4.5 → 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- require('../dist/cli').cli();
2
+ require('../dist/cli');
package/dist/cli.d.ts CHANGED
@@ -1,3 +1,2 @@
1
- declare function cli(): void;
2
1
 
3
- export { cli };
2
+ export { }
package/dist/cli.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @agilebot/eslint-config v0.4.5
2
+ * @license @agilebot/eslint-config v0.5.0
3
3
  *
4
4
  * Copyright (c) Agilebot, Inc. and its affiliates.
5
5
  *
@@ -14,10 +14,6 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
14
14
  var __getOwnPropNames = Object.getOwnPropertyNames;
15
15
  var __getProtoOf = Object.getPrototypeOf;
16
16
  var __hasOwnProp = Object.prototype.hasOwnProperty;
17
- var __export = (target, all) => {
18
- for (var name in all)
19
- __defProp(target, name, { get: all[name], enumerable: true });
20
- };
21
17
  var __copyProps = (to, from, except, desc) => {
22
18
  if (from && typeof from === "object" || typeof from === "function") {
23
19
  for (let key of __getOwnPropNames(from))
@@ -34,26 +30,18 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
34
30
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
35
31
  mod
36
32
  ));
37
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
38
-
39
- // src/cli.ts
40
- var cli_exports = {};
41
- __export(cli_exports, {
42
- cli: () => cli
43
- });
44
- module.exports = __toCommonJS(cli_exports);
45
33
 
46
34
  // src/cli/index.ts
47
- var import_node_fs = __toESM(require("fs"));
48
35
  var import_node_path = __toESM(require("path"));
49
36
  var import_eslint_utils = require("@agilebot/eslint-utils");
37
+ var import_yargs = __toESM(require("yargs"));
38
+ var import_helpers = require("yargs/helpers");
50
39
 
51
40
  // src/constants.ts
52
41
  var JS_EXTS = [".js", ".jsx", ".cjs", ".cjsx", ".mjs", ".mjsx"];
53
42
  var TS_EXTS = [".ts", ".tsx", ".cts", ".ctsx", ".mts", ".mtsx"];
54
43
  var VUE_EXTS = [".vue"];
55
44
  var DEFAULT_EXTS = [...JS_EXTS, ...TS_EXTS, ...VUE_EXTS];
56
- var IS_ESLINT = /^\.eslint.*/;
57
45
 
58
46
  // src/cli/index.ts
59
47
  function patch() {
@@ -68,34 +56,60 @@ function patch() {
68
56
  }
69
57
  function cli() {
70
58
  patch();
71
- const cwd = process.cwd();
72
- const has = {
73
- ext: false,
74
- fix: false,
75
- config: false,
76
- strict: false,
77
- checkIntl: false,
78
- progress: false,
79
- showWarningsInCI: false
80
- };
59
+ const argv = (0, import_yargs.default)((0, import_helpers.hideBin)(process.argv)).scriptName("eslint-agilebot").usage("eslint-agilebot [options] file.js [file.js] [dir]").options({
60
+ ext: {
61
+ type: "string",
62
+ description: "Specify file extensions",
63
+ default: DEFAULT_EXTS.join(",")
64
+ },
65
+ config: {
66
+ alias: "c",
67
+ type: "string",
68
+ description: "Use this configuration instead of .eslintrc.cjs, .eslintrc.js"
69
+ },
70
+ fix: {
71
+ type: "boolean",
72
+ description: "Automatically fix problems",
73
+ default: true
74
+ },
75
+ "check-intl": {
76
+ type: "boolean",
77
+ description: "Check for unused intl IDs",
78
+ default: false
79
+ },
80
+ progress: {
81
+ type: "boolean",
82
+ description: "Show progress bar",
83
+ default: false
84
+ },
85
+ "show-warnings-in-ci": {
86
+ type: "boolean",
87
+ description: "Show warnings in CI environment",
88
+ default: false
89
+ }
90
+ }).alias("h", "help").alias("v", "version").parseSync();
81
91
  const pkg = require.resolve("eslint/package.json");
82
92
  const bin = import_node_path.default.join(pkg, "..", "bin", "eslint.js");
83
- process.argv.forEach((arg) => {
84
- has.ext = has.ext || arg === "--ext";
85
- has.fix = has.fix || arg === "--fix";
86
- has.config = has.config || arg === "-c" || arg === "--config";
87
- has.strict = has.strict || arg === "--strict";
88
- has.checkIntl = has.checkIntl || arg === "--check-intl";
89
- has.progress = has.progress || arg === "--progress";
90
- has.showWarningsInCI = has.showWarningsInCI || arg === "--show-warnings-in-ci";
93
+ process.argv = process.argv.slice(0, 2);
94
+ if (argv._.length === 0) {
95
+ console.error(
96
+ "Error: 'patterns' must be a non-empty string or an array of non-empty strings"
97
+ );
98
+ process.exit(1);
99
+ }
100
+ argv._.forEach((pattern) => {
101
+ process.argv.push(String(pattern));
91
102
  });
92
- if (!has.fix) {
103
+ if (argv.fix) {
93
104
  process.argv.splice(2, 0, "--fix");
94
105
  }
95
- if (!has.ext) {
96
- process.argv.splice(2, 0, "--ext", DEFAULT_EXTS.join(","));
106
+ if (argv.ext) {
107
+ process.argv.splice(2, 0, "--ext", argv.ext);
97
108
  }
98
- if (has.progress && !(0, import_eslint_utils.isCI)()) {
109
+ if (argv.config) {
110
+ process.argv.splice(2, 0, "--config", argv.config);
111
+ }
112
+ if (argv.progress && !(0, import_eslint_utils.isCI)()) {
99
113
  process.argv.splice(
100
114
  2,
101
115
  0,
@@ -105,31 +119,18 @@ function cli() {
105
119
  "file-progress/activate: 1"
106
120
  );
107
121
  }
108
- if (!has.showWarningsInCI && (0, import_eslint_utils.isCI)()) {
122
+ if (!argv.showWarningsInCi && (0, import_eslint_utils.isCI)()) {
109
123
  console.warn(
110
124
  "Warning: eslint-agilebot will report errors only in CI environment"
111
125
  );
112
126
  process.argv.splice(2, 0, "--quiet");
113
127
  }
114
- if (has.checkIntl) {
115
- process.argv.splice(process.argv.indexOf("--check-intl"), 1);
128
+ if (argv.checkIntl) {
116
129
  process.argv.splice(2, 0, "--rule", "@agilebot/intl-id-unused: 1");
117
130
  }
118
- import_node_fs.default.readdir(cwd, (err, files) => {
119
- if (err) {
120
- throw err;
121
- }
122
- has.config = has.config || files.some((file) => {
123
- return IS_ESLINT.test(file);
124
- });
125
- if (has.strict && !has.config) {
126
- throw new Error("No ESLint configuration file found");
127
- }
128
- require(bin);
129
- });
131
+ require(bin);
130
132
  }
131
- // Annotate the CommonJS export names for ESM import in node:
132
- 0 && (module.exports = {
133
- cli
134
- });
133
+
134
+ // src/cli.ts
135
+ cli();
135
136
  if (module.exports.default) module.exports = module.exports.default;
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @agilebot/eslint-config v0.4.5
2
+ * @license @agilebot/eslint-config v0.5.0
3
3
  *
4
4
  * Copyright (c) Agilebot, Inc. and its affiliates.
5
5
  *
@@ -85,7 +85,7 @@ function standard() {
85
85
  // @ts-expect-error -- extracted rules from eslint-config-love
86
86
  false ? {} : (
87
87
  // @ts-expect-error -- extracted rules from eslint-config-love
88
- JSON.parse('{"class-methods-use-this":["off"],"dot-notation":["off"],"init-declarations":["off"],"max-params":["off"],"no-array-constructor":["off"],"no-dupe-class-members":["off"],"no-empty-function":["off"],"no-implied-eval":["off"],"no-loop-func":["off"],"no-redeclare":["off"],"no-unused-expressions":["off"],"no-unused-vars":["off"],"no-use-before-define":["off"],"no-useless-constructor":["off"],"prefer-promise-reject-errors":["off"],"@typescript-eslint/adjacent-overload-signatures":["error"],"@typescript-eslint/array-type":["error",{"default":"array-simple"}],"@typescript-eslint/await-thenable":["error"],"@typescript-eslint/ban-ts-comment":["error",{"ts-expect-error":"allow-with-description","ts-ignore":true,"ts-nocheck":true,"ts-check":false,"minimumDescriptionLength":3}],"@typescript-eslint/ban-tslint-comment":["error"],"@typescript-eslint/class-methods-use-this":["error",{"exceptMethods":[],"enforceForClassFields":true,"ignoreOverrideMethods":false,"ignoreClassesThatImplementAnInterface":false}],"@typescript-eslint/class-literal-property-style":["error","fields"],"@typescript-eslint/consistent-generic-constructors":["error","constructor"],"@typescript-eslint/consistent-indexed-object-style":["error","record"],"@typescript-eslint/consistent-type-assertions":["error",{"assertionStyle":"as","objectLiteralTypeAssertions":"never"}],"@typescript-eslint/consistent-type-definitions":["error","interface"],"@typescript-eslint/consistent-type-exports":["error",{"fixMixedExportsWithInlineTypeSpecifier":true}],"@typescript-eslint/consistent-type-imports":["error",{"prefer":"type-imports","disallowTypeAnnotations":true,"fixStyle":"inline-type-imports"}],"@typescript-eslint/dot-notation":["error",{"allowIndexSignaturePropertyAccess":false,"allowKeywords":true,"allowPattern":"","allowPrivateClassPropertyAccess":false,"allowProtectedClassPropertyAccess":false}],"@typescript-eslint/explicit-function-return-type":["error",{"allowExpressions":true,"allowHigherOrderFunctions":true,"allowTypedFunctionExpressions":true,"allowDirectConstAssertionInArrowFunctions":true}],"@typescript-eslint/init-declarations":["error","always"],"@typescript-eslint/max-params":["error",{"max":4}],"@typescript-eslint/method-signature-style":["error"],"@typescript-eslint/naming-convention":["error",{"selector":"variableLike","leadingUnderscore":"allow","trailingUnderscore":"allow","format":["camelCase","PascalCase","UPPER_CASE"]}],"@typescript-eslint/no-array-constructor":["error"],"@typescript-eslint/no-array-delete":["error"],"@typescript-eslint/no-base-to-string":["error"],"@typescript-eslint/no-confusing-non-null-assertion":["error"],"@typescript-eslint/no-confusing-void-expression":["error",{"ignoreArrowShorthand":false,"ignoreVoidOperator":false}],"@typescript-eslint/no-dupe-class-members":["error"],"@typescript-eslint/no-duplicate-enum-values":["error"],"@typescript-eslint/no-duplicate-type-constituents":["error",{"ignoreIntersections":false,"ignoreUnions":false}],"@typescript-eslint/no-dynamic-delete":["error"],"@typescript-eslint/no-empty-function":["error",{"allow":[]}],"@typescript-eslint/no-explicit-any":["error",{"fixToUnknown":false,"ignoreRestArgs":false}],"@typescript-eslint/no-extra-non-null-assertion":["error"],"@typescript-eslint/no-extraneous-class":["error",{"allowWithDecorator":true}],"@typescript-eslint/no-empty-object-type":["error",{"allowInterfaces":"with-single-extends","allowObjectTypes":"never"}],"@typescript-eslint/no-floating-promises":["error"],"@typescript-eslint/no-for-in-array":["error"],"@typescript-eslint/no-implied-eval":["error"],"@typescript-eslint/no-import-type-side-effects":["error"],"@typescript-eslint/no-inferrable-types":["error",{"ignoreParameters":false,"ignoreProperties":false}],"@typescript-eslint/no-invalid-void-type":["error"],"@typescript-eslint/no-loop-func":["error"],"@typescript-eslint/no-misused-new":["error"],"@typescript-eslint/no-misused-promises":["error"],"@typescript-eslint/no-namespace":["error"],"@typescript-eslint/no-non-null-asserted-optional-chain":["error"],"@typescript-eslint/no-non-null-assertion":["error"],"@typescript-eslint/no-redeclare":["error",{"builtinGlobals":false}],"@typescript-eslint/no-require-imports":["error",{"allow":[],"allowAsImport":false}],"@typescript-eslint/no-this-alias":["error",{"allowDestructuring":true}],"@typescript-eslint/no-unnecessary-boolean-literal-compare":["error"],"@typescript-eslint/no-unnecessary-type-assertion":["error"],"@typescript-eslint/no-unnecessary-type-constraint":["error"],"@typescript-eslint/no-unsafe-argument":["error"],"@typescript-eslint/no-unsafe-function-type":["error"],"@typescript-eslint/no-unused-expressions":["error",{"allowShortCircuit":true,"allowTernary":true,"allowTaggedTemplates":true,"enforceForJSX":false}],"@typescript-eslint/no-unused-vars":["error",{"args":"none","caughtErrors":"none","ignoreRestSiblings":true,"vars":"all"}],"@typescript-eslint/no-use-before-define":["error",{"functions":false,"classes":false,"enums":false,"variables":false,"typedefs":false}],"@typescript-eslint/no-useless-constructor":["error"],"@typescript-eslint/no-wrapper-object-types":["error"],"@typescript-eslint/non-nullable-type-assertion-style":["error"],"@typescript-eslint/only-throw-error":["error",{"allowThrowingAny":false,"allowThrowingUnknown":false}],"@typescript-eslint/prefer-function-type":["error"],"@typescript-eslint/prefer-includes":["error"],"@typescript-eslint/prefer-nullish-coalescing":["error",{"ignoreConditionalTests":false,"ignoreMixedLogicalExpressions":false}],"@typescript-eslint/prefer-optional-chain":["error"],"@typescript-eslint/prefer-promise-reject-errors":["error"],"@typescript-eslint/prefer-readonly":["error"],"@typescript-eslint/prefer-reduce-type-parameter":["error"],"@typescript-eslint/prefer-return-this-type":["error"],"@typescript-eslint/promise-function-async":["error"],"@typescript-eslint/require-array-sort-compare":["error",{"ignoreStringArrays":true}],"@typescript-eslint/restrict-plus-operands":["error",{"skipCompoundAssignments":false}],"@typescript-eslint/restrict-template-expressions":["error",{"allowNumber":true}],"@typescript-eslint/return-await":["error","always"],"@typescript-eslint/strict-boolean-expressions":["error",{"allowString":false,"allowNumber":false,"allowNullableObject":false,"allowNullableBoolean":false,"allowNullableString":false,"allowNullableNumber":false,"allowAny":false}],"@typescript-eslint/triple-slash-reference":["error",{"lib":"never","path":"never","types":"never"}],"@typescript-eslint/unbound-method":["error",{"ignoreStatic":false}],"accessor-pairs":["error",{"setWithoutGet":true,"getWithoutSet":false,"enforceForClassMembers":true}],"array-callback-return":["error",{"allowImplicit":false,"allowVoid":false,"checkForEach":false}],"constructor-super":["error"],"curly":["error","multi-line"],"default-case-last":["error"],"eqeqeq":["error","always",{"null":"ignore"}],"new-cap":["error",{"newIsCap":true,"capIsNew":false,"properties":true}],"no-async-promise-executor":["error"],"no-caller":["error"],"no-case-declarations":["error"],"no-class-assign":["error"],"no-compare-neg-zero":["error"],"no-cond-assign":["error"],"no-const-assign":["error"],"no-constant-condition":["error",{"checkLoops":false}],"no-control-regex":["error"],"no-debugger":["error"],"no-delete-var":["error"],"no-dupe-args":["error"],"no-dupe-keys":["error"],"no-duplicate-case":["error"],"no-useless-backreference":["error"],"no-empty":["error",{"allowEmptyCatch":true}],"no-empty-character-class":["error"],"no-empty-pattern":["error"],"no-eval":["error"],"no-ex-assign":["error"],"no-extend-native":["error"],"no-extra-bind":["error"],"no-extra-boolean-cast":["error"],"no-fallthrough":["error"],"no-func-assign":["error"],"no-global-assign":["error"],"no-import-assign":["error"],"no-invalid-regexp":["error"],"no-irregular-whitespace":["error"],"no-iterator":["error"],"no-labels":["error",{"allowLoop":false,"allowSwitch":false}],"no-lone-blocks":["error"],"no-loss-of-precision":["error"],"no-misleading-character-class":["error"],"no-prototype-builtins":["error"],"no-useless-catch":["error"],"no-multi-str":["error"],"no-new":["error"],"no-new-func":["error"],"no-new-symbol":["error"],"no-new-wrappers":["error"],"no-obj-calls":["error"],"no-object-constructor":["error"],"no-octal":["error"],"no-octal-escape":["error"],"no-proto":["error"],"no-regex-spaces":["error"],"no-return-assign":["error","except-parens"],"no-self-assign":["error",{"props":true}],"no-self-compare":["error"],"no-sequences":["error"],"no-shadow-restricted-names":["error"],"no-sparse-arrays":["error"],"no-template-curly-in-string":["error"],"no-this-before-super":["error"],"no-throw-literal":["off"],"no-undef-init":["error"],"no-unexpected-multiline":["error"],"no-unmodified-loop-condition":["error"],"no-unneeded-ternary":["error",{"defaultAssignment":false}],"no-unreachable":["error"],"no-unreachable-loop":["error"],"no-unsafe-finally":["error"],"no-unsafe-negation":["error"],"no-useless-call":["error"],"no-useless-computed-key":["error"],"no-useless-escape":["error"],"no-useless-rename":["error"],"no-useless-return":["error"],"no-var":["error"],"no-void":["error",{"allowAsStatement":true}],"no-with":["error"],"object-shorthand":["warn","properties"],"one-var":["error",{"initialized":"never"}],"prefer-const":["error",{"destructuring":"all","ignoreReadBeforeAssign":false}],"prefer-regex-literals":["error",{"disallowRedundantWrapping":true}],"symbol-description":["error"],"unicode-bom":["error","never"],"use-isnan":["error",{"enforceForSwitchCase":true,"enforceForIndexOf":true}],"valid-typeof":["error",{"requireStringLiterals":true}],"yoda":["error","never"],"import/export":["error"],"import/first":["error"],"import/no-absolute-path":["error",{"esmodule":true,"commonjs":true,"amd":false}],"import/no-duplicates":["error"],"import/no-named-default":["error"],"import/no-webpack-loader-syntax":["error"],"n/handle-callback-err":["error","^(err|error)$"],"n/no-callback-literal":["error"],"n/no-deprecated-api":["error"],"n/no-exports-assign":["error"],"n/no-new-require":["error"],"n/no-path-concat":["error"],"n/process-exit-as-throw":["error"],"promise/param-names":["error"]}')
88
+ JSON.parse('{"class-methods-use-this":["off"],"dot-notation":["off"],"init-declarations":["off"],"max-params":["off"],"no-array-constructor":["off"],"no-dupe-class-members":["off"],"no-empty-function":["off"],"no-implied-eval":["off"],"no-loop-func":["off"],"no-magic-numbers":["off"],"no-redeclare":["off"],"no-unused-expressions":["off"],"no-unused-vars":["off"],"no-use-before-define":["off"],"no-useless-constructor":["off"],"prefer-promise-reject-errors":["off"],"@typescript-eslint/adjacent-overload-signatures":["error"],"@typescript-eslint/array-type":["error",{"default":"array-simple"}],"@typescript-eslint/await-thenable":["error"],"@typescript-eslint/ban-ts-comment":["error",{"ts-expect-error":"allow-with-description","ts-ignore":true,"ts-nocheck":true,"ts-check":false,"minimumDescriptionLength":3}],"@typescript-eslint/ban-tslint-comment":["error"],"@typescript-eslint/class-methods-use-this":["error",{"exceptMethods":[],"enforceForClassFields":true,"ignoreOverrideMethods":false,"ignoreClassesThatImplementAnInterface":false}],"@typescript-eslint/class-literal-property-style":["error","fields"],"@typescript-eslint/consistent-generic-constructors":["error","constructor"],"@typescript-eslint/consistent-indexed-object-style":["error","record"],"@typescript-eslint/consistent-type-assertions":["error",{"assertionStyle":"as","objectLiteralTypeAssertions":"never"}],"@typescript-eslint/consistent-type-definitions":["error","interface"],"@typescript-eslint/consistent-type-exports":["error",{"fixMixedExportsWithInlineTypeSpecifier":true}],"@typescript-eslint/consistent-type-imports":["error",{"prefer":"type-imports","disallowTypeAnnotations":true,"fixStyle":"inline-type-imports"}],"@typescript-eslint/dot-notation":["error",{"allowIndexSignaturePropertyAccess":false,"allowKeywords":true,"allowPattern":"","allowPrivateClassPropertyAccess":false,"allowProtectedClassPropertyAccess":false}],"@typescript-eslint/explicit-function-return-type":["error",{"allowExpressions":true,"allowHigherOrderFunctions":true,"allowTypedFunctionExpressions":true,"allowDirectConstAssertionInArrowFunctions":true}],"@typescript-eslint/init-declarations":["error","always"],"@typescript-eslint/max-params":["error",{"max":4}],"@typescript-eslint/method-signature-style":["error"],"@typescript-eslint/naming-convention":["error",{"selector":"variableLike","leadingUnderscore":"allow","trailingUnderscore":"allow","format":["camelCase","PascalCase","UPPER_CASE"]}],"@typescript-eslint/no-array-constructor":["error"],"@typescript-eslint/no-array-delete":["error"],"@typescript-eslint/no-base-to-string":["error"],"@typescript-eslint/no-confusing-non-null-assertion":["error"],"@typescript-eslint/no-confusing-void-expression":["error",{"ignoreArrowShorthand":false,"ignoreVoidOperator":false}],"@typescript-eslint/no-deprecated":["warn"],"@typescript-eslint/no-dupe-class-members":["error"],"@typescript-eslint/no-duplicate-enum-values":["error"],"@typescript-eslint/no-duplicate-type-constituents":["error",{"ignoreIntersections":false,"ignoreUnions":false}],"@typescript-eslint/no-dynamic-delete":["error"],"@typescript-eslint/no-empty-function":["error",{"allow":[]}],"@typescript-eslint/no-explicit-any":["error",{"fixToUnknown":false,"ignoreRestArgs":false}],"@typescript-eslint/no-extra-non-null-assertion":["error"],"@typescript-eslint/no-extraneous-class":["error",{"allowWithDecorator":true}],"@typescript-eslint/no-empty-object-type":["error",{"allowInterfaces":"with-single-extends","allowObjectTypes":"never"}],"@typescript-eslint/no-floating-promises":["error"],"@typescript-eslint/no-for-in-array":["error"],"@typescript-eslint/no-implied-eval":["error"],"@typescript-eslint/no-import-type-side-effects":["error"],"@typescript-eslint/no-inferrable-types":["error",{"ignoreParameters":false,"ignoreProperties":false}],"@typescript-eslint/no-invalid-void-type":["error"],"@typescript-eslint/no-loop-func":["error"],"@typescript-eslint/no-magic-numbers":["error",{"ignore":[],"ignoreArrayIndexes":false,"ignoreDefaultValues":false,"ignoreClassFieldInitialValues":false,"enforceConst":true,"detectObjects":true,"ignoreEnums":true,"ignoreNumericLiteralTypes":false,"ignoreReadonlyClassProperties":true,"ignoreTypeIndexes":false}],"@typescript-eslint/no-meaningless-void-operator":["error",{"checkNever":true}],"@typescript-eslint/no-misused-new":["error"],"@typescript-eslint/no-misused-promises":["error"],"@typescript-eslint/no-namespace":["error"],"@typescript-eslint/no-non-null-asserted-optional-chain":["error"],"@typescript-eslint/no-non-null-assertion":["error"],"@typescript-eslint/no-redeclare":["error",{"builtinGlobals":false}],"@typescript-eslint/no-require-imports":["error",{"allow":[],"allowAsImport":false}],"@typescript-eslint/no-this-alias":["error",{"allowDestructuring":true}],"@typescript-eslint/no-unnecessary-boolean-literal-compare":["error"],"@typescript-eslint/no-unnecessary-type-assertion":["error"],"@typescript-eslint/no-unnecessary-type-constraint":["error"],"@typescript-eslint/no-unsafe-argument":["error"],"@typescript-eslint/no-unsafe-function-type":["error"],"@typescript-eslint/no-unused-expressions":["error",{"allowShortCircuit":true,"allowTernary":true,"allowTaggedTemplates":true,"enforceForJSX":false}],"@typescript-eslint/no-unused-vars":["error",{"args":"none","caughtErrors":"none","ignoreRestSiblings":true,"vars":"all"}],"@typescript-eslint/no-use-before-define":["error",{"functions":false,"classes":false,"enums":false,"variables":false,"typedefs":false}],"@typescript-eslint/no-useless-constructor":["error"],"@typescript-eslint/no-wrapper-object-types":["error"],"@typescript-eslint/non-nullable-type-assertion-style":["error"],"@typescript-eslint/only-throw-error":["error",{"allowThrowingAny":false,"allowThrowingUnknown":false}],"@typescript-eslint/prefer-function-type":["error"],"@typescript-eslint/prefer-includes":["error"],"@typescript-eslint/prefer-nullish-coalescing":["error",{"ignoreConditionalTests":false,"ignoreMixedLogicalExpressions":false}],"@typescript-eslint/prefer-optional-chain":["error"],"@typescript-eslint/prefer-promise-reject-errors":["error"],"@typescript-eslint/prefer-readonly":["error"],"@typescript-eslint/prefer-reduce-type-parameter":["error"],"@typescript-eslint/prefer-return-this-type":["error"],"@typescript-eslint/promise-function-async":["error"],"@typescript-eslint/require-array-sort-compare":["error",{"ignoreStringArrays":true}],"@typescript-eslint/restrict-plus-operands":["error",{"skipCompoundAssignments":false}],"@typescript-eslint/restrict-template-expressions":["error",{"allowNumber":true}],"@typescript-eslint/return-await":["error","always"],"@typescript-eslint/strict-boolean-expressions":["error",{"allowString":false,"allowNumber":false,"allowNullableObject":false,"allowNullableBoolean":false,"allowNullableString":false,"allowNullableNumber":false,"allowAny":false}],"@typescript-eslint/triple-slash-reference":["error",{"lib":"never","path":"never","types":"never"}],"@typescript-eslint/unbound-method":["error",{"ignoreStatic":false}],"accessor-pairs":["error",{"setWithoutGet":true,"getWithoutSet":false,"enforceForClassMembers":true}],"array-callback-return":["error",{"allowImplicit":false,"allowVoid":false,"checkForEach":false}],"constructor-super":["error"],"curly":["error","multi-line"],"default-case-last":["error"],"eqeqeq":["error","always",{"null":"ignore"}],"new-cap":["error",{"newIsCap":true,"capIsNew":false,"properties":true}],"no-async-promise-executor":["error"],"no-caller":["error"],"no-case-declarations":["error"],"no-class-assign":["error"],"no-compare-neg-zero":["error"],"no-cond-assign":["error"],"no-const-assign":["error"],"no-constant-condition":["error",{"checkLoops":false}],"no-control-regex":["error"],"no-debugger":["error"],"no-delete-var":["error"],"no-dupe-args":["error"],"no-dupe-keys":["error"],"no-duplicate-case":["error"],"no-useless-backreference":["error"],"no-empty":["error",{"allowEmptyCatch":true}],"no-empty-character-class":["error"],"no-empty-pattern":["error"],"no-eval":["error"],"no-ex-assign":["error"],"no-extend-native":["error"],"no-extra-bind":["error"],"no-extra-boolean-cast":["error"],"no-fallthrough":["error"],"no-func-assign":["error"],"no-global-assign":["error"],"no-import-assign":["error"],"no-invalid-regexp":["error"],"no-irregular-whitespace":["error"],"no-iterator":["error"],"no-labels":["error",{"allowLoop":false,"allowSwitch":false}],"no-lone-blocks":["error"],"no-loss-of-precision":["error"],"no-misleading-character-class":["error"],"no-prototype-builtins":["error"],"no-useless-catch":["error"],"no-multi-str":["error"],"no-new":["error"],"no-new-func":["error"],"no-new-symbol":["error"],"no-new-wrappers":["error"],"no-obj-calls":["error"],"no-object-constructor":["error"],"no-octal":["error"],"no-octal-escape":["error"],"no-proto":["error"],"no-regex-spaces":["error"],"no-return-assign":["error","except-parens"],"no-self-assign":["error",{"props":true}],"no-self-compare":["error"],"no-sequences":["error"],"no-shadow-restricted-names":["error"],"no-sparse-arrays":["error"],"no-template-curly-in-string":["error"],"no-this-before-super":["error"],"no-throw-literal":["off"],"no-undef-init":["error"],"no-unexpected-multiline":["error"],"no-unmodified-loop-condition":["error"],"no-unneeded-ternary":["error",{"defaultAssignment":false}],"no-unreachable":["error"],"no-unreachable-loop":["error"],"no-unsafe-finally":["error"],"no-unsafe-negation":["error"],"no-useless-call":["error"],"no-useless-computed-key":["error"],"no-useless-escape":["error"],"no-useless-rename":["error"],"no-useless-return":["error"],"no-var":["error"],"no-void":["error",{"allowAsStatement":true}],"no-with":["error"],"object-shorthand":["warn","properties"],"one-var":["error",{"initialized":"never"}],"prefer-const":["error",{"destructuring":"all","ignoreReadBeforeAssign":false}],"prefer-regex-literals":["error",{"disallowRedundantWrapping":true}],"symbol-description":["error"],"unicode-bom":["error","never"],"use-isnan":["error",{"enforceForSwitchCase":true,"enforceForIndexOf":true}],"valid-typeof":["error",{"requireStringLiterals":true}],"yoda":["error","never"],"import/export":["error"],"import/first":["error"],"import/no-absolute-path":["error",{"esmodule":true,"commonjs":true,"amd":false}],"import/no-duplicates":["error"],"import/no-named-default":["error"],"import/no-webpack-loader-syntax":["error"],"n/handle-callback-err":["error","^(err|error)$"],"n/no-callback-literal":["error"],"n/no-deprecated-api":["error"],"n/no-exports-assign":["error"],"n/no-new-require":["error"],"n/no-path-concat":["error"],"n/process-exit-as-throw":["error"],"promise/param-names":["error"]}')
89
89
  )
90
90
  );
91
91
  Object.entries(originalStdRules).forEach(([key, value]) => {
@@ -155,7 +155,11 @@ function standardDisabled() {
155
155
  "@typescript-eslint/no-explicit-any": "off",
156
156
  // v57.0.0
157
157
  "@typescript-eslint/init-declarations": "off",
158
- "@typescript-eslint/no-empty-function": "off"
158
+ "@typescript-eslint/no-empty-function": "off",
159
+ // v64.0.0
160
+ "@typescript-eslint/no-deprecated": "off",
161
+ // v65.0.0
162
+ "@typescript-eslint/no-magic-numbers": "off"
159
163
  }
160
164
  };
161
165
  }
@@ -742,7 +746,8 @@ function godaddy() {
742
746
  "no-case-declarations": "off",
743
747
  "callback-return": "off",
744
748
  "unicorn/prefer-string-slice": "off",
745
- "unicorn/prefer-string-replace-all": "off"
749
+ "unicorn/prefer-string-replace-all": "off",
750
+ "new-cap": "off"
746
751
  }
747
752
  };
748
753
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agilebot/eslint-config",
3
- "version": "0.4.5",
3
+ "version": "0.5.0",
4
4
  "description": "Agilebot's ESLint config",
5
5
  "bin": {
6
6
  "eslint-agilebot": "bin/eslint-agilebot"
@@ -27,10 +27,10 @@
27
27
  "eslint-config-godaddy": "^6.0.0",
28
28
  "eslint-config-prettier": "^9.1.0",
29
29
  "eslint-import-resolver-oxc": "^0.3.0",
30
- "eslint-import-resolver-typescript": "^3.6.1",
30
+ "eslint-import-resolver-typescript": "^3.6.3",
31
31
  "eslint-plugin-file-progress": "^1.5.0",
32
32
  "eslint-plugin-import-x": "^4.0.0",
33
- "eslint-plugin-jsdoc": "^50.2.2",
33
+ "eslint-plugin-jsdoc": "^50.2.3",
34
34
  "eslint-plugin-jsx-a11y": "^6.9.0",
35
35
  "eslint-plugin-n": "^17.10.2",
36
36
  "eslint-plugin-no-relative-import-paths": "^1.5.5",
@@ -39,18 +39,20 @@
39
39
  "eslint-plugin-promise": "^7.1.0",
40
40
  "eslint-plugin-react": "^7.35.0",
41
41
  "eslint-plugin-unicorn": "^55.0.0",
42
- "eslint-plugin-unused-imports": "^4.1.3",
43
- "eslint-plugin-vue": "^9.27.0",
42
+ "eslint-plugin-unused-imports": "^4.1.4",
43
+ "eslint-plugin-vue": "^9.28.0",
44
44
  "eslint-plugin-you-dont-need-lodash-underscore": "^6.13.0",
45
45
  "vue-eslint-parser": "^9.4.3",
46
- "@agilebot/eslint-utils": "0.4.5"
46
+ "yargs": "^17.7.2",
47
+ "@agilebot/eslint-utils": "0.5.0"
47
48
  },
48
49
  "devDependencies": {
49
- "eslint-config-love": "^63.0.0"
50
+ "@types/yargs": "^17.0.33",
51
+ "eslint-config-love": "^66.0.0"
50
52
  },
51
53
  "peerDependencies": {
52
54
  "eslint": "^7.0.0 || ^8.0.0 || ^9.0.0",
53
- "@agilebot/eslint-plugin": "0.4.5"
55
+ "@agilebot/eslint-plugin": "0.5.0"
54
56
  },
55
57
  "files": [
56
58
  "bin",
@@ -58,6 +60,7 @@
58
60
  ],
59
61
  "scripts": {
60
62
  "build": "tsup",
63
+ "dev:cli": "tsx src/cli.ts",
61
64
  "lint": "eslint-agilebot src"
62
65
  }
63
66
  }