Switch to shared ESLint config (#302)

This commit is contained in:
Will Lorey 2021-08-12 11:28:29 -07:00 коммит произвёл GitHub
Родитель 6c2d9b4d51
Коммит bb9358b75a
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
5 изменённых файлов: 182 добавлений и 52 удалений

Просмотреть файл

@ -1,38 +1,3 @@
module.exports = {
"env": {
"es6": true,
"node": true
},
"parser": "@typescript-eslint/parser",
"parserOptions": {
"project": "tsconfig.json",
"sourceType": "module"
},
"plugins": [
"@typescript-eslint",
"import"
],
"extends": [
"eslint:recommended",
"plugin:@typescript-eslint/recommended",
"plugin:@typescript-eslint/recommended-requiring-type-checking"
],
"rules": {
"no-unused-vars": "off",
"no-useless-escape": "off",
"no-inner-declarations": "off",
"no-case-declarations": "off",
"@typescript-eslint/prefer-regexp-exec": "off",
"@typescript-eslint/no-unused-vars": [
"error",
{ "argsIgnorePattern": "^_" }
],
"@typescript-eslint/no-inferrable-types": "off",
"@typescript-eslint/unbound-method": "off",
"@typescript-eslint/no-unnecessary-type-assertion": "off",
"@typescript-eslint/restrict-template-expressions": "off",
"@typescript-eslint/no-namespace": "off",
"@typescript-eslint/ban-types": "off",
"@typescript-eslint/require-await": "off"
}
"extends": "@microsoft/eslint-config-azuretools"
};

190
package-lock.json сгенерированный
Просмотреть файл

@ -29,6 +29,7 @@
"ws": "7.4.6"
},
"devDependencies": {
"@microsoft/eslint-config-azuretools": "^0.1.0",
"@types/form-data": "2.2.1",
"@types/fs-extra": "^9.0.11",
"@types/http-proxy-agent": "2.0.1",
@ -42,7 +43,6 @@
"@types/vscode": "1.48.0",
"@types/ws": "6.0.1",
"@typescript-eslint/eslint-plugin": "^4.14.2",
"@typescript-eslint/parser": "^4.14.2",
"eslint": "^7.19.0",
"eslint-plugin-import": "^2.22.1",
"fs-extra": "^9.1.0",
@ -377,6 +377,20 @@
"node": ">=8"
}
},
"node_modules/@microsoft/eslint-config-azuretools": {
"version": "0.1.0",
"resolved": "https://registry.npmjs.org/@microsoft/eslint-config-azuretools/-/eslint-config-azuretools-0.1.0.tgz",
"integrity": "sha512-1H95Y6RzUxl96BHneJeLdf2zsJFTZA1Ho6O6lAhky/mfYRulXFOGzeWyffwNScWdWFkHxGSmec5XnkQhoHKy5A==",
"dev": true,
"dependencies": {
"@typescript-eslint/parser": "^4.28.5"
},
"peerDependencies": {
"@typescript-eslint/eslint-plugin": ">=4",
"eslint": ">=7",
"eslint-plugin-import": ">=2"
}
},
"node_modules/@nodelib/fs.scandir": {
"version": "2.1.4",
"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.4.tgz",
@ -683,14 +697,14 @@
}
},
"node_modules/@typescript-eslint/parser": {
"version": "4.26.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.26.0.tgz",
"integrity": "sha512-b4jekVJG9FfmjUfmM4VoOItQhPlnt6MPOBUL0AQbiTmm+SSpSdhHYlwayOm4IW9KLI/4/cRKtQCmDl1oE2OlPg==",
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.29.1.tgz",
"integrity": "sha512-3fL5iN20hzX3Q4OkG7QEPFjZV2qsVGiDhEwwh+EkmE/w7oteiOvUNzmpu5eSwGJX/anCryONltJ3WDmAzAoCMg==",
"dev": true,
"dependencies": {
"@typescript-eslint/scope-manager": "4.26.0",
"@typescript-eslint/types": "4.26.0",
"@typescript-eslint/typescript-estree": "4.26.0",
"@typescript-eslint/scope-manager": "4.29.1",
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/typescript-estree": "4.29.1",
"debug": "^4.3.1"
},
"engines": {
@ -709,6 +723,95 @@
}
}
},
"node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/scope-manager": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.29.1.tgz",
"integrity": "sha512-Hzv/uZOa9zrD/W5mftZa54Jd5Fed3tL6b4HeaOpwVSabJK8CJ+2MkDasnX/XK4rqP5ZTWngK1ZDeCi6EnxPQ7A==",
"dev": true,
"dependencies": {
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/visitor-keys": "4.29.1"
},
"engines": {
"node": "^8.10.0 || ^10.13.0 || >=11.10.1"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/typescript-eslint"
}
},
"node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/types": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.29.1.tgz",
"integrity": "sha512-Jj2yu78IRfw4nlaLtKjVaGaxh/6FhofmQ/j8v3NXmAiKafbIqtAPnKYrf0sbGjKdj0hS316J8WhnGnErbJ4RCA==",
"dev": true,
"engines": {
"node": "^8.10.0 || ^10.13.0 || >=11.10.1"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/typescript-eslint"
}
},
"node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/typescript-estree": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.29.1.tgz",
"integrity": "sha512-lIkkrR9E4lwZkzPiRDNq0xdC3f2iVCUjw/7WPJ4S2Sl6C3nRWkeE1YXCQ0+KsiaQRbpY16jNaokdWnm9aUIsfw==",
"dev": true,
"dependencies": {
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/visitor-keys": "4.29.1",
"debug": "^4.3.1",
"globby": "^11.0.3",
"is-glob": "^4.0.1",
"semver": "^7.3.5",
"tsutils": "^3.21.0"
},
"engines": {
"node": "^10.12.0 || >=12.0.0"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/typescript-eslint"
},
"peerDependenciesMeta": {
"typescript": {
"optional": true
}
}
},
"node_modules/@typescript-eslint/parser/node_modules/@typescript-eslint/visitor-keys": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.29.1.tgz",
"integrity": "sha512-zLqtjMoXvgdZY/PG6gqA73V8BjqPs4af1v2kiiETBObp+uC6gRYnJLmJHxC0QyUrrHDLJPIWNYxoBV3wbcRlag==",
"dev": true,
"dependencies": {
"@typescript-eslint/types": "4.29.1",
"eslint-visitor-keys": "^2.0.0"
},
"engines": {
"node": "^8.10.0 || ^10.13.0 || >=11.10.1"
},
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/typescript-eslint"
}
},
"node_modules/@typescript-eslint/parser/node_modules/semver": {
"version": "7.3.5",
"resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz",
"integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==",
"dev": true,
"dependencies": {
"lru-cache": "^6.0.0"
},
"bin": {
"semver": "bin/semver.js"
},
"engines": {
"node": ">=10"
}
},
"node_modules/@typescript-eslint/scope-manager": {
"version": "4.26.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.26.0.tgz",
@ -10253,6 +10356,15 @@
}
}
},
"@microsoft/eslint-config-azuretools": {
"version": "0.1.0",
"resolved": "https://registry.npmjs.org/@microsoft/eslint-config-azuretools/-/eslint-config-azuretools-0.1.0.tgz",
"integrity": "sha512-1H95Y6RzUxl96BHneJeLdf2zsJFTZA1Ho6O6lAhky/mfYRulXFOGzeWyffwNScWdWFkHxGSmec5XnkQhoHKy5A==",
"dev": true,
"requires": {
"@typescript-eslint/parser": "^4.28.5"
}
},
"@nodelib/fs.scandir": {
"version": "2.1.4",
"resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.4.tgz",
@ -10519,15 +10631,67 @@
}
},
"@typescript-eslint/parser": {
"version": "4.26.0",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.26.0.tgz",
"integrity": "sha512-b4jekVJG9FfmjUfmM4VoOItQhPlnt6MPOBUL0AQbiTmm+SSpSdhHYlwayOm4IW9KLI/4/cRKtQCmDl1oE2OlPg==",
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.29.1.tgz",
"integrity": "sha512-3fL5iN20hzX3Q4OkG7QEPFjZV2qsVGiDhEwwh+EkmE/w7oteiOvUNzmpu5eSwGJX/anCryONltJ3WDmAzAoCMg==",
"dev": true,
"requires": {
"@typescript-eslint/scope-manager": "4.26.0",
"@typescript-eslint/types": "4.26.0",
"@typescript-eslint/typescript-estree": "4.26.0",
"@typescript-eslint/scope-manager": "4.29.1",
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/typescript-estree": "4.29.1",
"debug": "^4.3.1"
},
"dependencies": {
"@typescript-eslint/scope-manager": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.29.1.tgz",
"integrity": "sha512-Hzv/uZOa9zrD/W5mftZa54Jd5Fed3tL6b4HeaOpwVSabJK8CJ+2MkDasnX/XK4rqP5ZTWngK1ZDeCi6EnxPQ7A==",
"dev": true,
"requires": {
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/visitor-keys": "4.29.1"
}
},
"@typescript-eslint/types": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.29.1.tgz",
"integrity": "sha512-Jj2yu78IRfw4nlaLtKjVaGaxh/6FhofmQ/j8v3NXmAiKafbIqtAPnKYrf0sbGjKdj0hS316J8WhnGnErbJ4RCA==",
"dev": true
},
"@typescript-eslint/typescript-estree": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.29.1.tgz",
"integrity": "sha512-lIkkrR9E4lwZkzPiRDNq0xdC3f2iVCUjw/7WPJ4S2Sl6C3nRWkeE1YXCQ0+KsiaQRbpY16jNaokdWnm9aUIsfw==",
"dev": true,
"requires": {
"@typescript-eslint/types": "4.29.1",
"@typescript-eslint/visitor-keys": "4.29.1",
"debug": "^4.3.1",
"globby": "^11.0.3",
"is-glob": "^4.0.1",
"semver": "^7.3.5",
"tsutils": "^3.21.0"
}
},
"@typescript-eslint/visitor-keys": {
"version": "4.29.1",
"resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.29.1.tgz",
"integrity": "sha512-zLqtjMoXvgdZY/PG6gqA73V8BjqPs4af1v2kiiETBObp+uC6gRYnJLmJHxC0QyUrrHDLJPIWNYxoBV3wbcRlag==",
"dev": true,
"requires": {
"@typescript-eslint/types": "4.29.1",
"eslint-visitor-keys": "^2.0.0"
}
},
"semver": {
"version": "7.3.5",
"resolved": "https://registry.npmjs.org/semver/-/semver-7.3.5.tgz",
"integrity": "sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==",
"dev": true,
"requires": {
"lru-cache": "^6.0.0"
}
}
}
},
"@typescript-eslint/scope-manager": {

Просмотреть файл

@ -216,6 +216,7 @@
"which": "which tsc"
},
"devDependencies": {
"@microsoft/eslint-config-azuretools": "^0.1.0",
"@types/form-data": "2.2.1",
"@types/fs-extra": "^9.0.11",
"@types/http-proxy-agent": "2.0.1",
@ -229,7 +230,6 @@
"@types/vscode": "1.48.0",
"@types/ws": "6.0.1",
"@typescript-eslint/eslint-plugin": "^4.14.2",
"@typescript-eslint/parser": "^4.14.2",
"eslint": "^7.19.0",
"eslint-plugin-import": "^2.22.1",
"fs-extra": "^9.1.0",

Просмотреть файл

@ -4,6 +4,7 @@
*--------------------------------------------------------------------------------------------*/
import { Environment } from "@azure/ms-rest-azure-env";
// eslint-disable-next-line import/no-internal-modules
import { AuthenticationContext, MemoryCache } from "@azure/ms-rest-nodeauth/node_modules/adal-node";
import { UserCodeInfo } from "adal-node";
import { env, EventEmitter, MessageItem, Uri, UriHandler, window } from "vscode";

Просмотреть файл

@ -14,9 +14,9 @@ import { tryGetKeyTar } from "../../utils/keytar";
import { localize } from "../../utils/localize";
import { isADFS } from "../environments";
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-unsafe-assignment
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-unsafe-assignment, import/no-internal-modules
const CacheDriver = require('adal-node/lib/cache-driver');
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access
// eslint-disable-next-line @typescript-eslint/no-var-requires, @typescript-eslint/no-unsafe-assignment, @typescript-eslint/no-unsafe-member-access, import/no-internal-modules
const createLogContext = require('adal-node/lib/log').createLogContext;
const keytar = tryGetKeyTar();