npm audit fix & npm update (#70)

* npm audit fix & modify eslint rules

* update axios, @types/jest, eslint-plugin-jest

* update @octokit/rest, @typescript-eslint/parser

* update @actions/github
This commit is contained in:
Naoki Oketani
2020-09-11 22:04:02 +09:00
committed by GitHub
parent 75b171622a
commit 7b23c85c0d
5 changed files with 4858 additions and 25841 deletions

View File

@@ -1,6 +1,6 @@
{ {
"plugins": ["jest", "@typescript-eslint"], "plugins": ["jest", "@typescript-eslint"],
"extends": ["plugin:github/es6"], "extends": ["plugin:github/typescript"],
"parser": "@typescript-eslint/parser", "parser": "@typescript-eslint/parser",
"parserOptions": { "parserOptions": {
"ecmaVersion": 9, "ecmaVersion": 9,
@@ -11,18 +11,43 @@
"eslint-comments/no-use": "off", "eslint-comments/no-use": "off",
"import/no-namespace": "off", "import/no-namespace": "off",
"no-unused-vars": "off", "no-unused-vars": "off",
"@typescript-eslint/no-unused-vars": "error",
"@typescript-eslint/explicit-member-accessibility": "off", "@typescript-eslint/explicit-member-accessibility": "off",
"@typescript-eslint/no-require-imports": "error", "@typescript-eslint/no-require-imports": "error",
"@typescript-eslint/array-type": "error", "@typescript-eslint/array-type": "off",
"@typescript-eslint/await-thenable": "error", "@typescript-eslint/await-thenable": "error",
"@typescript-eslint/ban-ts-ignore": "error", "@typescript-eslint/ban-ts-comment": "error",
"camelcase": "off", "camelcase": "off",
"@typescript-eslint/camelcase": "error",
"@typescript-eslint/class-name-casing": "error",
"@typescript-eslint/explicit-function-return-type": ["error", {"allowExpressions": true}], "@typescript-eslint/explicit-function-return-type": ["error", {"allowExpressions": true}],
"@typescript-eslint/func-call-spacing": ["error", "never"], "@typescript-eslint/func-call-spacing": ["error", "never"],
"@typescript-eslint/generic-type-naming": ["error", "^[A-Z][A-Za-z]*$"], "@typescript-eslint/naming-convention": [
"error",
{
"selector": "default",
"format": ["camelCase"]
},
{
"selector": "class",
"format": ["PascalCase"]
},
{
"selector": "interface",
"format": ["PascalCase"]
},
{
"selector": "typeAlias",
"format": ["PascalCase"]
},
{
"selector": "property",
"format": null
},
{
"selector": "variable",
"format": ["camelCase", "UPPER_CASE"],
"leadingUnderscore": "allow",
"trailingUnderscore": "allow"
}
],
"@typescript-eslint/no-array-constructor": "error", "@typescript-eslint/no-array-constructor": "error",
"@typescript-eslint/no-empty-interface": "error", "@typescript-eslint/no-empty-interface": "error",
"@typescript-eslint/no-explicit-any": "error", "@typescript-eslint/no-explicit-any": "error",
@@ -34,6 +59,7 @@
"@typescript-eslint/no-non-null-assertion": "warn", "@typescript-eslint/no-non-null-assertion": "warn",
"@typescript-eslint/no-unnecessary-qualifier": "error", "@typescript-eslint/no-unnecessary-qualifier": "error",
"@typescript-eslint/no-unnecessary-type-assertion": "error", "@typescript-eslint/no-unnecessary-type-assertion": "error",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-useless-constructor": "error", "@typescript-eslint/no-useless-constructor": "error",
"@typescript-eslint/no-var-requires": "error", "@typescript-eslint/no-var-requires": "error",
"@typescript-eslint/prefer-for-of": "warn", "@typescript-eslint/prefer-for-of": "warn",

25866
dist/index.js vendored

File diff suppressed because it is too large Load Diff

4759
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -26,26 +26,26 @@
"author": "Naoki Oketani <okepy.naoki@gmail.com>", "author": "Naoki Oketani <okepy.naoki@gmail.com>",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@actions/core": "^1.2.4", "@actions/core": "^1.2.5",
"@actions/github": "^2.2.0", "@actions/github": "^4.0.0",
"@octokit/rest": "^17.9.2", "@octokit/rest": "^18.0.5",
"axios": "^0.19.2", "axios": "^0.20.0",
"strip-ansi": "^6.0.0" "strip-ansi": "^6.0.0"
}, },
"devDependencies": { "devDependencies": {
"@types/jest": "^25.2.3", "@types/jest": "^26.0.13",
"@types/node": "^14.0.5", "@types/node": "^14.10.0",
"@typescript-eslint/parser": "^3.0.0", "@typescript-eslint/parser": "^4.1.0",
"@zeit/ncc": "^0.22.3", "@zeit/ncc": "^0.22.3",
"eslint": "^7.1.0", "eslint": "^7.8.1",
"eslint-plugin-github": "^3.4.1", "eslint-plugin-github": "^4.1.1",
"eslint-plugin-jest": "^23.13.1", "eslint-plugin-jest": "^24.0.0",
"graphql": "^15.0.0", "graphql": "^15.3.0",
"jest": "^26.0.1", "jest": "^26.4.2",
"jest-circus": "^26.0.1", "jest-circus": "^26.4.2",
"js-yaml": "^3.14.0", "js-yaml": "^3.14.0",
"prettier": "^2.0.5", "prettier": "^2.1.1",
"ts-jest": "^26.0.0", "ts-jest": "^26.3.0",
"typescript": "^3.9.3" "typescript": "^3.9.7"
} }
} }

View File

@@ -67,7 +67,7 @@ export async function run(): Promise<void> {
if (existingIssueNumber !== null) { if (existingIssueNumber !== null) {
const {data: createdComment} = await octokit.issues.createComment({ const {data: createdComment} = await octokit.issues.createComment({
...github.context.repo, ...github.context.repo,
issue_number: existingIssueNumber, // eslint-disable-line @typescript-eslint/camelcase issue_number: existingIssueNumber,
body: option.body body: option.body
}) })
core.debug(`comment ${createdComment.url}`) core.debug(`comment ${createdComment.url}`)