diff --git a/.automation/generated/linter-helps.json b/.automation/generated/linter-helps.json index 15193e33d4a..7b9210cf1be 100644 --- a/.automation/generated/linter-helps.json +++ b/.automation/generated/linter-helps.json @@ -9639,6 +9639,35 @@ "", "Use \"trivy [command] --help\" for more information about a command." ], + "ts-standard": [ + "ts-standard - Standard for TypeScript! (https://github.com/standard/ts-standard)", + "", + "Usage:", + " ts-standard [FILES...]", + "", + " If FILES is omitted, all JavaScript/TypeScript source files (*.js, *.jsx, *.mjs, *.cjs, *.ts, *.tsx)", + " in the current working directory are checked, recursively.", + "", + " Certain paths (node_modules/, coverage/, vendor/, *.min.js, and", + " files/folders that begin with '.' like .git/) are automatically ignored.", + "", + " Paths in a project's root .gitignore file are also automatically ignored.", + "", + "Flags:", + " --fix Automatically fix problems", + " -p, --project Specify ts-config location (default: ./tsconfig.eslint.json or ./tsconfig.json)", + " --version Show current version", + " -h, --help Show usage information", + "", + "Flags (advanced):", + " --stdin Read file text from stdin", + " --ext Specify JavaScript/TypeScript file extensions", + " --global Declare global variable", + " --plugin Use custom eslint plugin", + " --env Use custom eslint environment", + " --parser Use custom ts/js parser (default: @typescript-eslint/parser)", + "" + ], "tsqllint": [ "running tsqllint", "", diff --git a/.automation/generated/linter-links-previews.json b/.automation/generated/linter-links-previews.json index 151d0157c46..f7a90a8320f 100644 --- a/.automation/generated/linter-links-previews.json +++ b/.automation/generated/linter-links-previews.json @@ -539,6 +539,11 @@ "image": null, "title": "Redirecting" }, + "ts-standard": { + "description": "English \u2022 Espan\u0303ol (Latinoame\u0301rica) \u2022 Franc\u0327ais \u2022 Bahasa Indonesia \u2022 Italiano (Italian) \u2022 \u65e5\u672c\u8a9e (Japanese) \u2022 \u1112\u1161\u11ab\u1100\u116e\u11a8\u110b\u1165 (Korean) \u2022 Portugue\u0302s (Brasil) \u2022 \u7b80\u4f53\u4e2d\u6587 (Simplified Chinese) \u2022 \u7e41\u9ad4\u4e2d\u6587 (Taiwanese Mandarin).", + "image": null, + "title": "JavaScript Standard Style" + }, "tsqllint": { "description": "Configurable linting for TSQL. Contribute to tsqllint/tsqllint development by creating an account on GitHub.", "image": "https://opengraph.githubassets.com/07bcefab8d31eb93bc746724c678639f64a396bb33c2f36f56b4c47d73906d60/tsqllint/tsqllint", diff --git a/.automation/generated/linter-versions.json b/.automation/generated/linter-versions.json index 7f1205cf80f..d18e7ff94b0 100644 --- a/.automation/generated/linter-versions.json +++ b/.automation/generated/linter-versions.json @@ -104,6 +104,7 @@ "terrascan": "1.18.1", "tflint": "0.46.1", "trivy": "0.42.1", + "ts-standard": "12.0.2", "tsqllint": "1.15.3.0", "v8r": "2.0.0", "vale": "2.27.0", diff --git a/.automation/test/typescript/reports/ERROR-TYPESCRIPT_STANDARD.txt b/.automation/test/typescript/reports/ERROR-TYPESCRIPT_STANDARD.txt index dabd0f6c39e..5b24a52d652 100644 --- a/.automation/test/typescript/reports/ERROR-TYPESCRIPT_STANDARD.txt +++ b/.automation/test/typescript/reports/ERROR-TYPESCRIPT_STANDARD.txt @@ -2,7 +2,7 @@ Results of standard linter (version 15.0.1) See documentation on https://megalinter.io/descriptors/typescript_standard/ ----------------------------------------------- -[ERROR] .automation/test/typescript/typescript_bad_1.ts - standard: Use JavaScript Standard Style (https://standardjs.com) - .automation/test/typescript/typescript_bad_1.ts:5:39: Parsing error: Unterminated regular expression literal. +[ERROR] .automation/test/typescript_standard/typescript_bad_1.ts + ts-standard: Use TypeScript Standard Style (https://standardjs.com) + .automation/test/typescript_standard/typescript_bad_1.ts:5:39: Parsing error: Unterminated regular expression literal. diff --git a/.automation/test/typescript/reports/SUCCESS-TYPESCRIPT_STANDARD.txt b/.automation/test/typescript/reports/SUCCESS-TYPESCRIPT_STANDARD.txt index eb7d3f41f98..a6cf4922ce6 100644 --- a/.automation/test/typescript/reports/SUCCESS-TYPESCRIPT_STANDARD.txt +++ b/.automation/test/typescript/reports/SUCCESS-TYPESCRIPT_STANDARD.txt @@ -2,6 +2,6 @@ Results of standard linter (version 15.0.1) See documentation on https://megalinter.io/descriptors/typescript_standard/ ----------------------------------------------- -[SUCCESS] .automation/test/typescript/typescript_good_1.ts +[SUCCESS] .automation/test/typescript_standard/typescript_good_1.ts diff --git a/.automation/test/typescript/reports/expected-TYPESCRIPT_STANDARD.tap b/.automation/test/typescript/reports/expected-TYPESCRIPT_STANDARD.tap deleted file mode 100644 index 1271fc8fc9d..00000000000 --- a/.automation/test/typescript/reports/expected-TYPESCRIPT_STANDARD.tap +++ /dev/null @@ -1,7 +0,0 @@ -TAP version 13 -1..2 -not ok 1 - typescript_bad_1.ts - --- - message: standard Use JavaScript Standard Style (https //standardjs.com)\n /tmp/lint/.automation/test/typescript/typescript_bad_1.ts 5 39 Parsing error Unterminated regular expression literal.\n - ... -ok 2 - typescript_good_1.ts diff --git a/.automation/test/typescript/tsconfig.json b/.automation/test/typescript/tsconfig.json new file mode 100644 index 00000000000..a7d85ef05bf --- /dev/null +++ b/.automation/test/typescript/tsconfig.json @@ -0,0 +1,13 @@ +{ + "compilerOptions": { + "noImplicitAny": true, + "strictNullChecks": true + }, + "files": [ + "typescript_bad_1.ts", + "typescript_good_1.ts", + "typescript_good_2.ts", + "typescript_fix_1.ts", + "typescript_fix_2.ts", + ] +} diff --git a/.automation/test/typescript/typescript_fix_1.ts b/.automation/test/typescript/typescript_fix_1.ts old mode 100644 new mode 100755 index df79f77f3ed..58dde598797 --- a/.automation/test/typescript/typescript_fix_1.ts +++ b/.automation/test/typescript/typescript_fix_1.ts @@ -1,2 +1,2 @@ -const str: String = 'foo'; -console.log(str) +const str: String = 'foo' + console.log(str) diff --git a/.automation/test/typescript/typescript_fix_2.ts b/.automation/test/typescript/typescript_fix_2.ts old mode 100644 new mode 100755 index df79f77f3ed..58dde598797 --- a/.automation/test/typescript/typescript_fix_2.ts +++ b/.automation/test/typescript/typescript_fix_2.ts @@ -1,2 +1,2 @@ -const str: String = 'foo'; -console.log(str) +const str: String = 'foo' + console.log(str) diff --git a/.automation/test/typescript/typescript_good_1.ts b/.automation/test/typescript/typescript_good_1.ts index 68ef03e098c..bc63d3e533b 100644 --- a/.automation/test/typescript/typescript_good_1.ts +++ b/.automation/test/typescript/typescript_good_1.ts @@ -1,4 +1,4 @@ -const spiderman = (person) => { +const spiderman = (person: string): string => { return 'Hello, ' + person } diff --git a/.automation/test/typescript/typescript_good_2.ts b/.automation/test/typescript/typescript_good_2.ts index 68ef03e098c..bc63d3e533b 100644 --- a/.automation/test/typescript/typescript_good_2.ts +++ b/.automation/test/typescript/typescript_good_2.ts @@ -1,4 +1,4 @@ -const spiderman = (person) => { +const spiderman = (person: string): string => { return 'Hello, ' + person } diff --git a/Dockerfile b/Dockerfile index 6c41c4b25d2..efec6a55cd4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -243,7 +243,8 @@ RUN npm --no-cache install --ignore-scripts --omit=dev \ tekton-lint \ prettyjson \ @typescript-eslint/eslint-plugin \ - @typescript-eslint/parser && \ + @typescript-eslint/parser \ + ts-standard && \ echo "Cleaning npm cache…" \ && npm cache clean --force || true \ && echo "Changing owner of node_modules files…" \ diff --git a/README.md b/README.md index 18b534a1369..534f938e40e 100644 --- a/README.md +++ b/README.md @@ -266,7 +266,7 @@ All linters are integrated in the [MegaLinter docker image](https://hub.docker.c | | [**SWIFT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift.md) | [**swiftlint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift_swiftlint.md)
[_SWIFT_SWIFTLINT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift_swiftlint.md) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TSX**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx.md) | [**eslint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx_eslint.md)
[_TSX_ESLINT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**eslint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_eslint.md)
[_TYPESCRIPT_ES_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**standard**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**ts-standard**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**prettier**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | | | [**Visual Basic .NET** (VBDOTNET)](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet.md) | [**dotnet-format**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet_dotnet_format.md)
[_VBDOTNET_DOTNET_FORMAT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet_dotnet_format.md) | [![GitHub stars](https://img.shields.io/github/stars/dotnet/format?cacheSeconds=3600)](https://github.com/dotnet/format) ![formatter](https://shields.io/badge/-format-yellow) | diff --git a/docs/all_linters.md b/docs/all_linters.md index 4c43d8d0564..509514b641e 100644 --- a/docs/all_linters.md +++ b/docs/all_linters.md @@ -94,7 +94,7 @@ | [**spectral**](https://github.com/stoplightio/spectral){target=_blank} | 6.8.0 | [Apache-2.0](licenses/spectral.md) | [![GitHub stars](https://img.shields.io/github/stars/stoplightio/spectral?cacheSeconds=3600)](https://github.com/stoplightio/spectral){target=_blank} | [OPENAPI](descriptors/openapi_spectral.md) | :white_circle: | [Repository](https://github.com/stoplightio/spectral){target=_blank} | | [**sql-lint**](https://github.com/joereynolds/sql-lint){target=_blank} | 1.0.0 | [MIT](licenses/sql-lint.md) | [![GitHub stars](https://img.shields.io/github/stars/joereynolds/sql-lint?cacheSeconds=3600)](https://github.com/joereynolds/sql-lint){target=_blank} | [SQL](descriptors/sql_sql_lint.md) | :white_circle: | [Repository](https://github.com/joereynolds/sql-lint){target=_blank} | | [**sqlfluff**](https://github.com/sqlfluff/sqlfluff){target=_blank} | 2.1.1 | [MIT](licenses/sqlfluff.md) | [![GitHub stars](https://img.shields.io/github/stars/sqlfluff/sqlfluff?cacheSeconds=3600)](https://github.com/sqlfluff/sqlfluff){target=_blank} | [SQL](descriptors/sql_sqlfluff.md) | :white_circle: | [Repository](https://github.com/sqlfluff/sqlfluff){target=_blank} | -| [**standard**](https://github.com/standard/standard){target=_blank} | 17.1.0 | [MIT](licenses/standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard){target=_blank} | [JAVASCRIPT](descriptors/javascript_standard.md)
[TYPESCRIPT](descriptors/typescript_standard.md) | :white_circle: | [Repository](https://github.com/standard/standard){target=_blank} | +| [**standard**](https://github.com/standard/standard){target=_blank} | 17.1.0 | [MIT](licenses/standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard){target=_blank} | [JAVASCRIPT](descriptors/javascript_standard.md) | :white_circle: | [Repository](https://github.com/standard/standard){target=_blank} | | [**stylelint**](https://github.com/stylelint/stylelint){target=_blank} | 15.7.0 | [MIT](licenses/stylelint.md) | [![GitHub stars](https://img.shields.io/github/stars/stylelint/stylelint?cacheSeconds=3600)](https://github.com/stylelint/stylelint){target=_blank} | [CSS](descriptors/css_stylelint.md) | :white_circle: | [Repository](https://github.com/stylelint/stylelint){target=_blank} | | [**swiftlint**](https://github.com/realm/SwiftLint){target=_blank} | 0.52.2 | [MIT](licenses/swiftlint.md) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint){target=_blank} | [SWIFT](descriptors/swift_swiftlint.md) | :white_circle: | [Repository](https://github.com/realm/SwiftLint){target=_blank} | | [**syft**](https://github.com/anchore/syft){target=_blank} | 0.83.1 | [Apache-2.0](licenses/syft.md) | [![GitHub stars](https://img.shields.io/github/stars/anchore/syft?cacheSeconds=3600)](https://github.com/anchore/syft){target=_blank} | [REPOSITORY](descriptors/repository_syft.md) | :white_circle: | [Repository](https://github.com/anchore/syft){target=_blank} | @@ -104,6 +104,7 @@ | [**terrascan**](https://github.com/tenable/terrascan){target=_blank} | 1.18.1 | [Apache-2.0](licenses/terrascan.md) | [![GitHub stars](https://img.shields.io/github/stars/tenable/terrascan?cacheSeconds=3600)](https://github.com/tenable/terrascan){target=_blank} | [TERRAFORM](descriptors/terraform_terrascan.md) | :white_circle: | [Repository](https://github.com/tenable/terrascan){target=_blank} | | [**tflint**](https://github.com/terraform-linters/tflint){target=_blank} | 0.46.1 | [MPL-2.0](licenses/tflint.md) | [![GitHub stars](https://img.shields.io/github/stars/terraform-linters/tflint?cacheSeconds=3600)](https://github.com/terraform-linters/tflint){target=_blank} | [TERRAFORM](descriptors/terraform_tflint.md) | :white_circle: | [Repository](https://github.com/terraform-linters/tflint){target=_blank} | | [**trivy**](https://github.com/aquasecurity/trivy){target=_blank} | 0.42.1 | [Apache-2.0](licenses/trivy.md) | [![GitHub stars](https://img.shields.io/github/stars/aquasecurity/trivy?cacheSeconds=3600)](https://github.com/aquasecurity/trivy){target=_blank} | [REPOSITORY](descriptors/repository_trivy.md) | :white_circle: | [Repository](https://github.com/aquasecurity/trivy){target=_blank} | +| [**ts-standard**](https://github.com/standard/ts-standard){target=_blank} | 12.0.2 | | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard){target=_blank} | [TYPESCRIPT](descriptors/typescript_standard.md) | :white_circle: | [Repository](https://github.com/standard/ts-standard){target=_blank} | | [**tsqllint**](https://github.com/tsqllint/tsqllint){target=_blank} | 1.15.3.0 | [MIT](licenses/tsqllint.md) | [![GitHub stars](https://img.shields.io/github/stars/tsqllint/tsqllint?cacheSeconds=3600)](https://github.com/tsqllint/tsqllint){target=_blank} | [SQL](descriptors/sql_tsqllint.md) | :white_circle: | [Repository](https://github.com/tsqllint/tsqllint){target=_blank} | | [**v8r**](https://github.com/chris48s/v8r){target=_blank} | 2.0.0 | [MIT](licenses/v8r.md) | [![GitHub stars](https://img.shields.io/github/stars/chris48s/v8r?cacheSeconds=3600)](https://github.com/chris48s/v8r){target=_blank} | [JSON](descriptors/json_v8r.md)
[YAML](descriptors/yaml_v8r.md) | :no_entry_sign: | [Repository](https://github.com/chris48s/v8r){target=_blank} | | [**vale**](https://github.com/errata-ai/vale){target=_blank} | 2.27.0 | [MIT](licenses/vale.md) | [![GitHub stars](https://img.shields.io/github/stars/errata-ai/vale?cacheSeconds=3600)](https://github.com/errata-ai/vale){target=_blank} | [SPELL](descriptors/spell_vale.md) | :white_circle: | [Repository](https://github.com/errata-ai/vale){target=_blank} | diff --git a/docs/descriptors/repository_gitleaks.md b/docs/descriptors/repository_gitleaks.md index bf4d28a7e5a..700f4853342 100644 --- a/docs/descriptors/repository_gitleaks.md +++ b/docs/descriptors/repository_gitleaks.md @@ -171,7 +171,7 @@ Use "gitleaks [command] --help" for more information about a command. - Dockerfile commands : ```dockerfile -FROM zricethezav/gitleaks:v8.16.4 as gitleaks +FROM zricethezav/gitleaks:v8.17.0 as gitleaks COPY --link --from=gitleaks /usr/bin/gitleaks /usr/bin/ ``` diff --git a/docs/descriptors/typescript.md b/docs/descriptors/typescript.md index 458f6f802d3..1eaafdce910 100644 --- a/docs/descriptors/typescript.md +++ b/docs/descriptors/typescript.md @@ -1,6 +1,6 @@ --- title: TYPESCRIPT linters in MegaLinter -description: eslint, standard, prettier are available to analyze TYPESCRIPT files in MegaLinter +description: eslint, ts-standard, prettier are available to analyze TYPESCRIPT files in MegaLinter --- @@ -9,11 +9,11 @@ description: eslint, standard, prettier are available to analyze TYPESCRIPT file ## Linters -| Linter | Additional | -|--------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| -| [**eslint**](typescript_eslint.md)
[_TYPESCRIPT_ES_](typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| [**standard**](typescript_standard.md)
[_TYPESCRIPT_STANDARD_](typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | -| [**prettier**](typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | +| Linter | Additional | +|-----------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| [**eslint**](typescript_eslint.md)
[_TYPESCRIPT_ES_](typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | +| [**ts-standard**](typescript_standard.md)
[_TYPESCRIPT_STANDARD_](typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | +| [**prettier**](typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | ## Linted files diff --git a/docs/descriptors/typescript_eslint.md b/docs/descriptors/typescript_eslint.md index ccb76f32439..ef4ceef2f74 100644 --- a/docs/descriptors/typescript_eslint.md +++ b/docs/descriptors/typescript_eslint.md @@ -59,7 +59,6 @@ Use eslint in your favorite IDE to catch errors before MegaLinter ! | | IDE | Extension Name | Install | |:---------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------|------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------:| -| | [Atom](https://atom.io/) | [linter-eslint](https://atom.io/packages/linter-eslint) | [Visit Web Site](https://atom.io/packages/linter-eslint){target=_blank} | | | [Brackets](https://brackets.io/) | [brackets-eslint](https://github.com/brackets-userland/brackets-eslint) | [Visit Web Site](https://github.com/brackets-userland/brackets-eslint){target=_blank} | | | [Eclipse](https://www.eclipse.org/) | [Tern-Linter-ESLint](https://github.com/angelozerr/tern.java/wiki/Tern-Linter-ESLint) | [Visit Web Site](https://github.com/angelozerr/tern.java/wiki/Tern-Linter-ESLint){target=_blank} | | | [Emacs](https://www.gnu.org/software/emacs/) | [flycheck](http://www.flycheck.org/en/latest/languages.html#javascript) | [Visit Web Site](http://www.flycheck.org/en/latest/languages.html#javascript){target=_blank} | diff --git a/docs/descriptors/typescript_prettier.md b/docs/descriptors/typescript_prettier.md index 7127dd35527..1b7c8185c65 100644 --- a/docs/descriptors/typescript_prettier.md +++ b/docs/descriptors/typescript_prettier.md @@ -54,9 +54,6 @@ Use prettier in your favorite IDE to catch errors before MegaLinter ! | | IDE | Extension Name | Install | |:--------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------|-----------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------:| -| | [Atom](https://atom.io/) | [prettier-atom](https://github.com/prettier/prettier-atom) | [Visit Web Site](https://github.com/prettier/prettier-atom){target=_blank} | -| | [Atom](https://atom.io/) | [atom-mprettier](https://github.com/t9md/atom-mprettier) | [Visit Web Site](https://github.com/t9md/atom-mprettier){target=_blank} | -| | [Atom](https://atom.io/) | [atom-miniprettier](https://github.com/duailibe/atom-miniprettier) | [Visit Web Site](https://github.com/duailibe/atom-miniprettier){target=_blank} | | | [Emacs](https://www.gnu.org/software/emacs/) | [prettier-emacs](https://github.com/prettier/prettier-emacs) | [Visit Web Site](https://github.com/prettier/prettier-emacs){target=_blank} | | | [Emacs](https://www.gnu.org/software/emacs/) | [prettier.el](https://github.com/jscheid/prettier.el) | [Visit Web Site](https://github.com/jscheid/prettier.el){target=_blank} | | | [Emacs](https://www.gnu.org/software/emacs/) | [apheleia](https://github.com/raxod502/apheleia) | [Visit Web Site](https://github.com/raxod502/apheleia){target=_blank} | diff --git a/docs/descriptors/typescript_standard.md b/docs/descriptors/typescript_standard.md index 38197ef8afd..734b578e002 100644 --- a/docs/descriptors/typescript_standard.md +++ b/docs/descriptors/typescript_standard.md @@ -1,36 +1,36 @@ --- -title: standard configuration in MegaLinter -description: How to use standard (configure, ignore files, ignore errors, help & version documentations) to analyze TYPESCRIPT files +title: ts-standard configuration in MegaLinter +description: How to use ts-standard (configure, ignore files, ignore errors, help & version documentations) to analyze TYPESCRIPT files ---
- standard + ts-standard
-[![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) [![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/standard/standard?sort=semver)](https://github.com/standard/standard/releases) [![GitHub last commit](https://img.shields.io/github/last-commit/standard/standard)](https://github.com/standard/standard/commits) [![GitHub commit activity](https://img.shields.io/github/commit-activity/y/standard/standard)](https://github.com/standard/standard/graphs/commit-activity/) [![GitHub contributors](https://img.shields.io/github/contributors/standard/standard)](https://github.com/standard/standard/graphs/contributors/) +[![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) [![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/standard/ts-standard?sort=semver)](https://github.com/standard/ts-standard/releases) [![GitHub last commit](https://img.shields.io/github/last-commit/standard/ts-standard)](https://github.com/standard/ts-standard/commits) [![GitHub commit activity](https://img.shields.io/github/commit-activity/y/standard/ts-standard)](https://github.com/standard/ts-standard/graphs/commit-activity/) [![GitHub contributors](https://img.shields.io/github/contributors/standard/ts-standard)](https://github.com/standard/ts-standard/graphs/contributors/) -## standard documentation +## ts-standard documentation -- Version in MegaLinter: **17.1.0** +- Version in MegaLinter: **12.0.2** - Visit [Official Web Site](https://standardjs.com/){target=_blank} -- See [Index of problems detected by standard](https://standardjs.com/rules.html){target=_blank} +- See [Index of problems detected by ts-standard](https://standardjs.com/rules.html){target=_blank} -[![standard - GitHub](https://gh-card.dev/repos/standard/standard.svg?fullname=)](https://github.com/standard/standard){target=_blank} +[![ts-standard - GitHub](https://gh-card.dev/repos/standard/ts-standard.svg?fullname=)](https://github.com/standard/ts-standard){target=_blank} ## Configuration in MegaLinter -- Enable standard by adding `TYPESCRIPT_STANDARD` in [ENABLE_LINTERS variable](https://megalinter.io/beta/configuration/#activation-and-deactivation) -- Disable standard by adding `TYPESCRIPT_STANDARD` in [DISABLE_LINTERS variable](https://megalinter.io/beta/configuration/#activation-and-deactivation) +- Enable ts-standard by adding `TYPESCRIPT_STANDARD` in [ENABLE_LINTERS variable](https://megalinter.io/beta/configuration/#activation-and-deactivation) +- Disable ts-standard by adding `TYPESCRIPT_STANDARD` in [DISABLE_LINTERS variable](https://megalinter.io/beta/configuration/#activation-and-deactivation) - Enable **autofixes** by adding `TYPESCRIPT_STANDARD` in [APPLY_FIXES variable](https://megalinter.io/beta/configuration/#apply-fixes) | Variable | Description | Default value | |-------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------| -| JAVASCRIPT_DEFAULT_STYLE | For standard to be active, JAVASCRIPT_DEFAULT_STYLE must be `standard` | `standard` | +| TYPESCRIPT_STANDARD | For ts-standard to be active, TYPESCRIPT_STANDARD must be `ts-standard` | `ts-standard` | | TYPESCRIPT_STANDARD_ARGUMENTS | User custom arguments to add in linter CLI call
Ex: `-s --foo "bar"` | | | TYPESCRIPT_STANDARD_FILTER_REGEX_INCLUDE | Custom regex including filter
Ex: `(src\|lib)` | Include every file | | TYPESCRIPT_STANDARD_FILTER_REGEX_EXCLUDE | Custom regex excluding filter
Ex: `(test\|examples)` | Exclude no file | @@ -42,22 +42,18 @@ description: How to use standard (configure, ignore files, ignore errors, help & | TYPESCRIPT_STANDARD_UNSECURED_ENV_VARIABLES | List of env variables explicitly not filtered before calling TYPESCRIPT_STANDARD and its pre/post commands | None | | TYPESCRIPT_STANDARD_DISABLE_ERRORS | Run linter but consider errors as warnings | `false` | | TYPESCRIPT_STANDARD_DISABLE_ERRORS_IF_LESS_THAN | Maximum number of errors allowed | `0` | -| TYPESCRIPT_STANDARD_CLI_EXECUTABLE | Override CLI executable | `['standard']` | +| TYPESCRIPT_STANDARD_CLI_EXECUTABLE | Override CLI executable | `['ts-standard']` | ## IDE Integration -Use standard in your favorite IDE to catch errors before MegaLinter ! +Use ts-standard in your favorite IDE to catch errors before MegaLinter ! -| | IDE | Extension Name | Install | -|:---------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------|-----------------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------------:| -| | [Atom](https://atom.io/) | [linter-js-standard](https://atom.io/packages/linter-js-standard) | [Visit Web Site](https://atom.io/packages/linter-js-standard){target=_blank} | -| | [Atom](https://atom.io/) | [linter-js-standard-engine](https://atom.io/packages/linter-js-standard-engine) | [Visit Web Site](https://atom.io/packages/linter-js-standard-engine){target=_blank} | -| | [Atom](https://atom.io/) | [standard-formatter](https://atom.io/packages/standard-formatter) | [Visit Web Site](https://atom.io/packages/standard-formatter){target=_blank} | -| | [Brackets](https://brackets.io/) | [brackets-standard](https://github.com/ishamf/brackets-standard/) | [Visit Web Site](https://github.com/ishamf/brackets-standard/){target=_blank} | -| | [IDEA](https://www.jetbrains.com/products.html#type=ide) | [native support](https://blog.jetbrains.com/webstorm/2017/01/webstorm-2017-1-eap-171-2272/) | [Visit Web Site](https://blog.jetbrains.com/webstorm/2017/01/webstorm-2017-1-eap-171-2272/){target=_blank} | -| | [Sublime Text](https://www.sublimetext.com/) | [SublimeLinter-contrib-standard](https://packagecontrol.io/packages/SublimeLinter-contrib-standard) | [Visit Web Site](https://packagecontrol.io/packages/SublimeLinter-contrib-standard){target=_blank} | -| | [Sublime Text](https://www.sublimetext.com/) | [StandardFormat](https://packagecontrol.io/packages/StandardFormat) | [Visit Web Site](https://packagecontrol.io/packages/StandardFormat){target=_blank} | -| | [Visual Studio Code](https://code.visualstudio.com/) | [https://marketplace.visualstudio.com/items?itemName=standard.vscode-standard](vscode-standard) | [Visit Web Site](vscode-standard){target=_blank} | +| | IDE | Extension Name | Install | +|:--------------------------------------------------------------------------------------------------------------------------------------------:|----------------------------------------------------------|-----------------------------------------------------------------------------------------------------|:----------------------------------------------------------------------------------------------------------:| +| | [IDEA](https://www.jetbrains.com/products.html#type=ide) | [native support](https://blog.jetbrains.com/webstorm/2017/01/webstorm-2017-1-eap-171-2272/) | [Visit Web Site](https://blog.jetbrains.com/webstorm/2017/01/webstorm-2017-1-eap-171-2272/){target=_blank} | +| | [Sublime Text](https://www.sublimetext.com/) | [SublimeLinter-contrib-standard](https://packagecontrol.io/packages/SublimeLinter-contrib-standard) | [Visit Web Site](https://packagecontrol.io/packages/SublimeLinter-contrib-standard){target=_blank} | +| | [Sublime Text](https://www.sublimetext.com/) | [StandardFormat](https://packagecontrol.io/packages/StandardFormat) | [Visit Web Site](https://packagecontrol.io/packages/StandardFormat){target=_blank} | +| | [Visual Studio Code](https://code.visualstudio.com/) | [https://marketplace.visualstudio.com/items?itemName=standard.vscode-standard](vscode-standard) | [Visit Web Site](vscode-standard){target=_blank} | ## MegaLinter Flavours @@ -79,48 +75,48 @@ This linter is available in the following flavours ### How the linting is performed -- standard is called once with the list of files as arguments (`list_of_files` CLI lint mode) +- ts-standard is called once with the list of files as arguments (`list_of_files` CLI lint mode) ### Example calls ```shell -standard --parser @typescript-eslint/parser --plugin @typescript-eslint/eslint-plugin myfile.ts +ts-standard myfile.ts ``` ```shell -standard --parser @typescript-eslint/parser --plugin @typescript-eslint/eslint-plugin --fix myfile.ts +ts-standard --fix myfile.ts ``` ### Help content ```shell -standard - Use JavaScript Standard Style (https://standardjs.com) +ts-standard - Standard for TypeScript! (https://github.com/standard/ts-standard) Usage: - standard [FILES...] + ts-standard [FILES...] - If FILES is omitted, all JavaScript source files (*.js, *.jsx, *.mjs, *.cjs) - in the current working directory are checked, recursively. + If FILES is omitted, all JavaScript/TypeScript source files (*.js, *.jsx, *.mjs, *.cjs, *.ts, *.tsx) + in the current working directory are checked, recursively. - Certain paths (node_modules/, coverage/, vendor/, *.min.js, and - files/folders that begin with '.' like .git/) are automatically ignored. + Certain paths (node_modules/, coverage/, vendor/, *.min.js, and + files/folders that begin with '.' like .git/) are automatically ignored. - Paths in a project's root .gitignore file are also automatically ignored. + Paths in a project's root .gitignore file are also automatically ignored. Flags: - --fix Automatically fix problems - --version Show current version - -h, --help Show usage information + --fix Automatically fix problems + -p, --project Specify ts-config location (default: ./tsconfig.eslint.json or ./tsconfig.json) + --version Show current version + -h, --help Show usage information Flags (advanced): - --stdin Read file text from stdin - --ext Specify JavaScript file extensions - --ignore Specify files to ignore - --global Declare global variable - --plugin Use custom eslint plugin - --env Use custom eslint environment - --parser Use custom js parser (e.g. babel-eslint) + --stdin Read file text from stdin + --ext Specify JavaScript/TypeScript file extensions + --global Declare global variable + --plugin Use custom eslint plugin + --env Use custom eslint environment + --parser Use custom ts/js parser (default: @typescript-eslint/parser) ``` @@ -128,6 +124,4 @@ Flags (advanced): - NPM packages (node.js): - [typescript](https://www.npmjs.com/package/typescript) - - [standard](https://www.npmjs.com/package/standard) - - [@typescript-eslint/eslint-plugin](https://www.npmjs.com/package/@typescript-eslint/eslint-plugin) - - [@typescript-eslint/parser](https://www.npmjs.com/package/@typescript-eslint/parser) + - [ts-standard](https://www.npmjs.com/package/ts-standard) diff --git a/docs/descriptors/xml_xmllint.md b/docs/descriptors/xml_xmllint.md index a02a35ef66e..0bf50fc8dc8 100644 --- a/docs/descriptors/xml_xmllint.md +++ b/docs/descriptors/xml_xmllint.md @@ -25,7 +25,7 @@ To apply file formatting you must set `XML_XMLLINT_CLI_LINT_MODE: file` and `XML | Variable | Description | Default value | |-----------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------| | XML_XMLLINT_AUTOFORMAT | If set to `true`, it will reformat and reindent the output | `false` | -| XML_XMLLINT_INDENT | The number of indentation spaces when `XML_XMLLINT_AUTOFORMAT` is `true` | `` | +| XML_XMLLINT_INDENT | The number of indentation spaces when `XML_XMLLINT_AUTOFORMAT` is `true` | ` ` | | XML_XMLLINT_ARGUMENTS | User custom arguments to add in linter CLI call
Ex: `-s --foo "bar"` | | | XML_XMLLINT_FILTER_REGEX_INCLUDE | Custom regex including filter
Ex: `(src\|lib)` | Include every file | | XML_XMLLINT_FILTER_REGEX_EXCLUDE | Custom regex excluding filter
Ex: `(test\|examples)` | Exclude no file | diff --git a/docs/flavors/cupcake.md b/docs/flavors/cupcake.md index c09398fc4ed..5a4783c816f 100644 --- a/docs/flavors/cupcake.md +++ b/docs/flavors/cupcake.md @@ -59,7 +59,7 @@ MegaLinter for the most commonly used languages | | [**SWIFT**](https://megalinter.io/beta/descriptors/swift/) | [**swiftlint**](https://megalinter.io/beta/descriptors/swift_swiftlint/)
[_SWIFT_SWIFTLINT_](https://megalinter.io/beta/descriptors/swift_swiftlint/) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TSX**](https://megalinter.io/beta/descriptors/tsx/) | [**eslint**](https://megalinter.io/beta/descriptors/tsx_eslint/)
[_TSX_ESLINT_](https://megalinter.io/beta/descriptors/tsx_eslint/) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**eslint**](https://megalinter.io/beta/descriptors/typescript_eslint/)
[_TYPESCRIPT_ES_](https://megalinter.io/beta/descriptors/typescript_eslint/) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**standard**](https://megalinter.io/beta/descriptors/typescript_standard/)
[_TYPESCRIPT_STANDARD_](https://megalinter.io/beta/descriptors/typescript_standard/) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**ts-standard**](https://megalinter.io/beta/descriptors/typescript_standard/)
[_TYPESCRIPT_STANDARD_](https://megalinter.io/beta/descriptors/typescript_standard/) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**prettier**](https://megalinter.io/beta/descriptors/typescript_prettier/)
[_TYPESCRIPT_PRETTIER_](https://megalinter.io/beta/descriptors/typescript_prettier/) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | ### Formats diff --git a/docs/flavors/javascript.md b/docs/flavors/javascript.md index e4e8637f212..1743903638d 100644 --- a/docs/flavors/javascript.md +++ b/docs/flavors/javascript.md @@ -37,7 +37,7 @@ Optimized for JAVASCRIPT or TYPESCRIPT based projects | | [**SQL**](https://megalinter.io/beta/descriptors/sql/) | [**sqlfluff**](https://megalinter.io/beta/descriptors/sql_sqlfluff/)
[_SQL_SQLFLUFF_](https://megalinter.io/beta/descriptors/sql_sqlfluff/) | [![GitHub stars](https://img.shields.io/github/stars/sqlfluff/sqlfluff?cacheSeconds=3600)](https://github.com/sqlfluff/sqlfluff) | | | [**TSX**](https://megalinter.io/beta/descriptors/tsx/) | [**eslint**](https://megalinter.io/beta/descriptors/tsx_eslint/)
[_TSX_ESLINT_](https://megalinter.io/beta/descriptors/tsx_eslint/) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**eslint**](https://megalinter.io/beta/descriptors/typescript_eslint/)
[_TYPESCRIPT_ES_](https://megalinter.io/beta/descriptors/typescript_eslint/) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**standard**](https://megalinter.io/beta/descriptors/typescript_standard/)
[_TYPESCRIPT_STANDARD_](https://megalinter.io/beta/descriptors/typescript_standard/) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**ts-standard**](https://megalinter.io/beta/descriptors/typescript_standard/)
[_TYPESCRIPT_STANDARD_](https://megalinter.io/beta/descriptors/typescript_standard/) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](https://megalinter.io/beta/descriptors/typescript/) | [**prettier**](https://megalinter.io/beta/descriptors/typescript_prettier/)
[_TYPESCRIPT_PRETTIER_](https://megalinter.io/beta/descriptors/typescript_prettier/) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | ### Formats diff --git a/docs/index.md b/docs/index.md index 4f7e5f3610f..7785aa06839 100644 --- a/docs/index.md +++ b/docs/index.md @@ -161,7 +161,7 @@ All linters are integrated in the [MegaLinter docker image](https://hub.docker.c | | [**SWIFT**](descriptors/swift.md) | [**swiftlint**](descriptors/swift_swiftlint.md)
[_SWIFT_SWIFTLINT_](descriptors/swift_swiftlint.md) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TSX**](descriptors/tsx.md) | [**eslint**](descriptors/tsx_eslint.md)
[_TSX_ESLINT_](descriptors/tsx_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](descriptors/typescript.md) | [**eslint**](descriptors/typescript_eslint.md)
[_TYPESCRIPT_ES_](descriptors/typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](descriptors/typescript.md) | [**standard**](descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](descriptors/typescript.md) | [**ts-standard**](descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](descriptors/typescript.md) | [**prettier**](descriptors/typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](descriptors/typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | | | [**Visual Basic .NET** (VBDOTNET)](descriptors/vbdotnet.md) | [**dotnet-format**](descriptors/vbdotnet_dotnet_format.md)
[_VBDOTNET_DOTNET_FORMAT_](descriptors/vbdotnet_dotnet_format.md) | [![GitHub stars](https://img.shields.io/github/stars/dotnet/format?cacheSeconds=3600)](https://github.com/dotnet/format) ![formatter](https://shields.io/badge/-format-yellow) | diff --git a/docs/json-schemas/configuration.html b/docs/json-schemas/configuration.html index ec39c26b713..979388fc3e1 100644 --- a/docs/json-schemas/configuration.html +++ b/docs/json-schemas/configuration.html @@ -119414,4 +119414,4 @@

- \ No newline at end of file + diff --git a/docs/supported-linters.md b/docs/supported-linters.md index 62df9b4440b..f735360ed56 100644 --- a/docs/supported-linters.md +++ b/docs/supported-linters.md @@ -68,7 +68,7 @@ All linters are integrated in the [MegaLinter docker image](https://hub.docker.c | | [**SWIFT**](descriptors/swift.md) | [**swiftlint**](descriptors/swift_swiftlint.md)
[_SWIFT_SWIFTLINT_](descriptors/swift_swiftlint.md) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TSX**](descriptors/tsx.md) | [**eslint**](descriptors/tsx_eslint.md)
[_TSX_ESLINT_](descriptors/tsx_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](descriptors/typescript.md) | [**eslint**](descriptors/typescript_eslint.md)
[_TYPESCRIPT_ES_](descriptors/typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](descriptors/typescript.md) | [**standard**](descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](descriptors/typescript.md) | [**ts-standard**](descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](descriptors/typescript.md) | [**prettier**](descriptors/typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](descriptors/typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | | | [**Visual Basic .NET** (VBDOTNET)](descriptors/vbdotnet.md) | [**dotnet-format**](descriptors/vbdotnet_dotnet_format.md)
[_VBDOTNET_DOTNET_FORMAT_](descriptors/vbdotnet_dotnet_format.md) | [![GitHub stars](https://img.shields.io/github/stars/dotnet/format?cacheSeconds=3600)](https://github.com/dotnet/format) ![formatter](https://shields.io/badge/-format-yellow) | diff --git a/flavors/cupcake/Dockerfile b/flavors/cupcake/Dockerfile index 690307c3d17..30e59ade31c 100644 --- a/flavors/cupcake/Dockerfile +++ b/flavors/cupcake/Dockerfile @@ -203,7 +203,8 @@ RUN npm --no-cache install --ignore-scripts --omit=dev \ sql-lint \ prettyjson \ @typescript-eslint/eslint-plugin \ - @typescript-eslint/parser && \ + @typescript-eslint/parser \ + ts-standard && \ echo "Cleaning npm cache…" \ && npm cache clean --force || true \ && echo "Changing owner of node_modules files…" \ diff --git a/flavors/javascript/Dockerfile b/flavors/javascript/Dockerfile index 74a3df20bf4..c81f237ca61 100644 --- a/flavors/javascript/Dockerfile +++ b/flavors/javascript/Dockerfile @@ -170,7 +170,8 @@ RUN npm --no-cache install --ignore-scripts --omit=dev \ tekton-lint \ prettyjson \ @typescript-eslint/eslint-plugin \ - @typescript-eslint/parser && \ + @typescript-eslint/parser \ + ts-standard && \ echo "Cleaning npm cache…" \ && npm cache clean --force || true \ && echo "Changing owner of node_modules files…" \ diff --git a/linters/typescript_standard/Dockerfile b/linters/typescript_standard/Dockerfile index 7e2eaea7c4c..dbc99286290 100644 --- a/linters/typescript_standard/Dockerfile +++ b/linters/typescript_standard/Dockerfile @@ -87,9 +87,7 @@ ENV NODE_OPTIONS="--max-old-space-size=8192" \ WORKDIR /node-deps RUN npm --no-cache install --ignore-scripts --omit=dev \ typescript \ - standard \ - @typescript-eslint/eslint-plugin \ - @typescript-eslint/parser && \ + ts-standard && \ echo "Cleaning npm cache…" \ && npm cache clean --force || true \ && echo "Changing owner of node_modules files…" \ diff --git a/mega-linter-runner/README.md b/mega-linter-runner/README.md index 584cec35d5b..956df0d3825 100644 --- a/mega-linter-runner/README.md +++ b/mega-linter-runner/README.md @@ -194,7 +194,7 @@ You can generate a ready-to-use [.mega-linter.yml configuration file](https://me | | [**SWIFT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift.md) | [**swiftlint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift_swiftlint.md)
[_SWIFT_SWIFTLINT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/swift_swiftlint.md) | [![GitHub stars](https://img.shields.io/github/stars/realm/SwiftLint?cacheSeconds=3600)](https://github.com/realm/SwiftLint) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TSX**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx.md) | [**eslint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx_eslint.md)
[_TSX_ESLINT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/tsx_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/jsx-eslint/eslint-plugin-react?cacheSeconds=3600)](https://github.com/jsx-eslint/eslint-plugin-react) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | | | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**eslint**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_eslint.md)
[_TYPESCRIPT_ES_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_eslint.md) | [![GitHub stars](https://img.shields.io/github/stars/typescript-eslint/typescript-eslint?cacheSeconds=3600)](https://github.com/typescript-eslint/typescript-eslint) ![autofix](https://shields.io/badge/-autofix-green) ![sarif](https://shields.io/badge/-SARIF-orange) | -| | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**standard**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/standard?cacheSeconds=3600)](https://github.com/standard/standard) ![autofix](https://shields.io/badge/-autofix-green) | +| | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**ts-standard**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md)
[_TYPESCRIPT_STANDARD_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_standard.md) | [![GitHub stars](https://img.shields.io/github/stars/standard/ts-standard?cacheSeconds=3600)](https://github.com/standard/ts-standard) ![autofix](https://shields.io/badge/-autofix-green) | | | [**TYPESCRIPT**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript.md) | [**prettier**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_prettier.md)
[_TYPESCRIPT_PRETTIER_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/typescript_prettier.md) | [![GitHub stars](https://img.shields.io/github/stars/prettier/prettier?cacheSeconds=3600)](https://github.com/prettier/prettier) ![formatter](https://shields.io/badge/-format-yellow) | | | [**Visual Basic .NET** (VBDOTNET)](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet.md) | [**dotnet-format**](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet_dotnet_format.md)
[_VBDOTNET_DOTNET_FORMAT_](https://github.com/oxsecurity/megalinter/tree/main/docs/descriptors/vbdotnet_dotnet_format.md) | [![GitHub stars](https://img.shields.io/github/stars/dotnet/format?cacheSeconds=3600)](https://github.com/dotnet/format) ![formatter](https://shields.io/badge/-format-yellow) | diff --git a/megalinter/descriptors/schemas/megalinter-configuration.jsonschema.json b/megalinter/descriptors/schemas/megalinter-configuration.jsonschema.json index 8f574b2886c..313c6cdba50 100644 --- a/megalinter/descriptors/schemas/megalinter-configuration.jsonschema.json +++ b/megalinter/descriptors/schemas/megalinter-configuration.jsonschema.json @@ -17439,7 +17439,7 @@ "$id": "#/properties/TYPESCRIPT_STANDARD_CLI_EXECUTABLE", "default": [ [ - "standard" + "ts-standard" ] ], "items": { diff --git a/megalinter/descriptors/typescript.megalinter-descriptor.yml b/megalinter/descriptors/typescript.megalinter-descriptor.yml index 6086c3fe2ea..70ece12def2 100644 --- a/megalinter/descriptors/typescript.megalinter-descriptor.yml +++ b/megalinter/descriptors/typescript.megalinter-descriptor.yml @@ -71,9 +71,6 @@ linters: - "@typescript-eslint/parser" - "@microsoft/eslint-formatter-sarif" ide: - atom: - - name: linter-eslint - url: https://atom.io/packages/linter-eslint brackets: - name: brackets-eslint url: https://github.com/brackets-userland/brackets-eslint @@ -100,43 +97,26 @@ linters: url: https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint # STANDARD - class: TypeScriptStandardLinter - linter_name: standard + linter_name: ts-standard + name: TYPESCRIPT_STANDARD activation_rules: - type: variable - variable: JAVASCRIPT_DEFAULT_STYLE - expected_value: standard - default_value: standard + variable: TYPESCRIPT_STANDARD + expected_value: ts-standard + default_value: ts-standard linter_url: https://standardjs.com/ - linter_repo: https://github.com/standard/standard + linter_repo: https://github.com/standard/ts-standard linter_rules_url: https://standardjs.com/rules.html linter_banner_image_url: https://github.com/standard/standard/raw/master/sticker.png - name: TYPESCRIPT_STANDARD cli_lint_mode: list_of_files - cli_lint_extra_args: - - "--parser" - - "@typescript-eslint/parser" - - "--plugin" - - "@typescript-eslint/eslint-plugin" cli_lint_fix_arg_name: "--fix" examples: - - "standard --parser @typescript-eslint/parser --plugin @typescript-eslint/eslint-plugin myfile.ts" - - "standard --parser @typescript-eslint/parser --plugin @typescript-eslint/eslint-plugin --fix myfile.ts" + - "ts-standard myfile.ts" + - "ts-standard --fix myfile.ts" install: npm: - - standard - - "@typescript-eslint/eslint-plugin" - - "@typescript-eslint/parser" + - ts-standard ide: - atom: - - name: linter-js-standard - url: https://atom.io/packages/linter-js-standard - - name: linter-js-standard-engine - url: https://atom.io/packages/linter-js-standard-engine - - name: standard-formatter - url: https://atom.io/packages/standard-formatter - brackets: - - name: brackets-standard - url: https://github.com/ishamf/brackets-standard/ idea: - name: native support url: https://blog.jetbrains.com/webstorm/2017/01/webstorm-2017-1-eap-171-2272/ @@ -181,13 +161,6 @@ linters: npm: - "prettier" ide: - atom: - - name: prettier-atom - url: https://github.com/prettier/prettier-atom - - name: atom-mprettier - url: https://github.com/t9md/atom-mprettier - - name: atom-miniprettier - url: https://github.com/duailibe/atom-miniprettier emacs: - name: prettier-emacs url: https://github.com/prettier/prettier-emacs diff --git a/megalinter/linters/TypeScriptStandardLinter.py b/megalinter/linters/TypeScriptStandardLinter.py index 18d59aea4d0..c1335eb9778 100644 --- a/megalinter/linters/TypeScriptStandardLinter.py +++ b/megalinter/linters/TypeScriptStandardLinter.py @@ -1,7 +1,7 @@ #!/usr/bin/env python3 """ Use Standard to lint js files -https://github.com/standard/standard +https://github.com/standard/ts-standard """ from megalinter import Linter, utilstest diff --git a/megalinter/tests/test_megalinter/linters/typescript_standard_test.py b/megalinter/tests/test_megalinter/linters/typescript_standard_test.py index ce639822f5d..d2a62ebf9f2 100644 --- a/megalinter/tests/test_megalinter/linters/typescript_standard_test.py +++ b/megalinter/tests/test_megalinter/linters/typescript_standard_test.py @@ -1,6 +1,6 @@ # !/usr/bin/env python3 """ -Unit tests for TYPESCRIPT linter standard +Unit tests for TYPESCRIPT linter ts-standard This class has been automatically @generated by .automation/build.py, please don't update it manually """ @@ -11,4 +11,4 @@ class typescript_standard_test(TestCase, LinterTestRoot): descriptor_id = "TYPESCRIPT" - linter_name = "standard" + linter_name = "ts-standard" diff --git a/mkdocs.yml b/mkdocs.yml index a0dd34582db..eb221054b07 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -198,7 +198,7 @@ nav: - "TYPESCRIPT": - "All TYPESCRIPT linters": "descriptors/typescript.md" - "eslint": "descriptors/typescript_eslint.md" - - "standard": "descriptors/typescript_standard.md" + - "ts-standard": "descriptors/typescript_standard.md" - "prettier": "descriptors/typescript_prettier.md" - "Visual Basic .NET (VBDOTNET)": - "All Visual Basic .NET (VBDOTNET) linters": "descriptors/vbdotnet.md"