-
-
Notifications
You must be signed in to change notification settings - Fork 279
upgrade code analyzer to v5 #6386
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 3 commits
3a3a468
a324d80
b14795a
15a3ce3
736fec3
4f74eea
297dd0e
172670a
f24a244
d0525ea
041d0d2
7bb138e
7bc1af5
e15bb77
37086de
9394321
7eefddf
f63376a
107bb0b
d04ae85
afddb25
6f1d5b6
e5cb09b
c0c6495
a92768e
9a955f5
7ea6c41
7bb9cde
73f7d7e
fc8525b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -401,7 +401,7 @@ RUN sf plugins install @salesforce/plugin-packaging@${NPM_SALESFORCE_PLUGIN_PACK | |
| ENV SF_AUTOUPDATE_DISABLE=true SF_CLI_DISABLE_AUTOUPDATE=true | ||
| # Linter install | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: Version mismatch: scanner version misdocumentedThe Additional Locations (2) |
||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -398,7 +398,7 @@ RUN sf plugins install @salesforce/plugin-packaging@${NPM_SALESFORCE_PLUGIN_PACK | |
| ENV SF_AUTOUPDATE_DISABLE=true SF_CLI_DISABLE_AUTOUPDATE=true | ||
| # Linter install | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: Incorrect scanner version regression in plugin updaterThe |
||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -399,7 +399,7 @@ RUN sf plugins install @salesforce/plugin-packaging@${NPM_SALESFORCE_PLUGIN_PACK | |
| ENV SF_AUTOUPDATE_DISABLE=true SF_CLI_DISABLE_AUTOUPDATE=true | ||
| # Linter install | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm trying to find why it is bumped to 5.5.0, if reverted back to adding a new key for the code-analyzer version of the linters. That version doesn't exist in sfdx scanner. |
||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -64,39 +64,37 @@ linters: | |
| linter_spdx_license: BSD-3-Clause | ||
| config_file_name: apex-pmd-ruleset.xml | ||
| cli_executable: sf | ||
| cli_config_arg_name: "--pmdconfig" | ||
| cli_config_arg_name: "--config-file" | ||
| cli_lint_extra_args: | ||
| - "scanner:run" | ||
| - "--engine" | ||
| - "pmd" | ||
| - "--target" | ||
| - '"./**/*"' | ||
| - "--severity-threshold" | ||
| - "2" | ||
| - "--outfile" | ||
| - "{{REPORT_FOLDER}}/sfdx-scanner-report-apex.csv" | ||
| - "--format" | ||
| - "csv" | ||
| - "code-analyzer run" | ||
| - "--rule-selector" | ||
| - "pmd:Recommended" | ||
| - "--workspace" | ||
| - "." | ||
| - "--output-file" | ||
| - "{{REPORT_FOLDER}}/code-analyzer-report-apex.csv" | ||
| - "--view" | ||
| - "table" | ||
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| cli_lint_mode: project | ||
| cli_help_extra_args: | ||
| - "scanner:run" | ||
| - "code-analyzer run" | ||
| cli_help_extra_commands: | ||
| - "sf scanner:rule:list" | ||
| - "sf code-analyzer rules" | ||
| cli_version_extra_args: | ||
| - "plugins" | ||
| - "plugins --core" | ||
| cli_version_arg_name: "" | ||
| version_extract_regex: "(?<=@salesforce/sfdx-scanner )\\d+(\\.\\d+)+" | ||
| version_extract_regex: "(?<=code-analyzer )\\d+(\\.\\d+)+" | ||
| cli_lint_errors_count: regex_sum | ||
| cli_lint_errors_regex: "found ([0-9]+) violation" | ||
| cli_lint_errors_regex: "severity: [1-3]" | ||
cursor[bot] marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| examples: | ||
| - "sf scanner:run" | ||
| - "sf code-analyzer run --rule-selector pmd:Recommended --workspace . --output-file results.csv" | ||
| install: | ||
| dockerfile: | ||
| - |- | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| # renovate: datasource=npm depName=@salesforce/code-analyzer | ||
echoix marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
| - |- | ||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| RUN sf plugins install @salesforce/code-analyzer@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
| ide: | ||
|
|
@@ -151,37 +149,39 @@ linters: | |
| cli_config_arg_name: ".eslintrc-aura.json" | ||
| cli_executable: sf | ||
| cli_lint_extra_args: | ||
| - "scanner:run" | ||
| - "--engine" | ||
| - "code-analyzer run" | ||
| - "--rule-selector" | ||
| - "eslint" | ||
| - "--workspace" | ||
| - "." | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: Aura Linter Uses Incorrect Rule SelectorThe |
||
| - "--target" | ||
| - "**/aura/**/*.js" | ||
| - "--severity-threshold" | ||
| - "2" | ||
| - "--outfile" | ||
| - "{{REPORT_FOLDER}}/sfdx-scanner-report-aura.csv" | ||
| - "--format" | ||
| - "csv" | ||
| - "--output-file" | ||
| - "{{REPORT_FOLDER}}/code-analyzer-report-aura.csv" | ||
| - "--view" | ||
| - "table" | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Bug: Salesforce Linter Argument Compatibility IssueThe Salesforce Aura and LWC linters mix Additional Locations (1)
cursor[bot] marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| cli_lint_mode: project | ||
| cli_help_extra_args: | ||
| - "scanner:run" | ||
| - "code-analyzer run" | ||
|
||
| cli_help_extra_commands: | ||
| - "sf scanner:rule:list" | ||
| - "sf code-analyzer rules --rule-selector eslint" | ||
| cli_version_extra_args: | ||
| - "plugins" | ||
| - "plugins --core" | ||
| cli_version_arg_name: "" | ||
| version_extract_regex: "(?<=@salesforce/sfdx-scanner )\\d+(\\.\\d+)+" | ||
| version_extract_regex: "(?<=code-analyzer )\\d+(\\.\\d+)+" | ||
| cli_lint_errors_count: regex_sum | ||
| cli_lint_errors_regex: "found ([0-9]+) violation" | ||
| cli_lint_errors_regex: "severity: [1-3]" | ||
| examples: | ||
| - "sf scanner:run" | ||
| - "sf code-analyzer run --rule-selector eslint --workspace . --file-glob '**/aura/**/*.js' --output-file results.csv" | ||
| install: | ||
| dockerfile: | ||
| - |- | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| # renovate: datasource=npm depName=@salesforce/code-analyzer | ||
echoix marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
| - |- | ||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| RUN sf plugins install @salesforce/code-analyzer@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
| ide: | ||
|
|
@@ -227,37 +227,39 @@ linters: | |
| cli_config_arg_name: ".eslintrc-lwc.json" | ||
| cli_executable: sf | ||
| cli_lint_extra_args: | ||
| - "scanner:run" | ||
| - "--engine" | ||
| - "eslint-lwc" | ||
| - "code-analyzer run" | ||
|
||
| - "--rule-selector" | ||
| - "eslint:LWC" | ||
| - "--workspace" | ||
| - "." | ||
| - "--target" | ||
| - "**/lwc/**/*.js" | ||
| - "--severity-threshold" | ||
| - "2" | ||
| - "--outfile" | ||
| - "{{REPORT_FOLDER}}/sfdx-scanner-report-lwc.csv" | ||
| - "--format" | ||
| - "csv" | ||
| - "--output-file" | ||
| - "{{REPORT_FOLDER}}/code-analyzer-report-lwc.csv" | ||
| - "--view" | ||
| - "table" | ||
echoix marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| cli_lint_mode: project | ||
| cli_help_extra_args: | ||
| - "scanner:run" | ||
| - "code-analyzer run" | ||
| cli_help_extra_commands: | ||
| - "sf scanner:rule:list" | ||
| - "sf code-analyzer rules --rule-selector eslint:LWC" | ||
| cli_version_extra_args: | ||
| - "plugins" | ||
| - "plugins --core" | ||
| cli_version_arg_name: "" | ||
| version_extract_regex: "(?<=@salesforce/sfdx-scanner )\\d+(\\.\\d+)+" | ||
| version_extract_regex: "(?<=code-analyzer )\\d+(\\.\\d+)+" | ||
| cli_lint_errors_count: regex_sum | ||
| cli_lint_errors_regex: "found ([0-9]+) violation" | ||
| cli_lint_errors_regex: "severity: [1-3]" | ||
| examples: | ||
| - "sf scanner:run" | ||
| - "sf code-analyzer run --rule-selector eslint:LWC --workspace . --target '**/lwc/**/*.js' --output-file report.csv" | ||
| install: | ||
| dockerfile: | ||
| - |- | ||
| # renovate: datasource=npm depName=@salesforce/sfdx-scanner | ||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=4.12.0 | ||
| # renovate: datasource=npm depName=@salesforce/code-analyzer | ||
echoix marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| ARG SALESFORCE_SFDX_SCANNER_VERSION=5.5.0 | ||
| - |- | ||
| RUN sf plugins install @salesforce/sfdx-scanner@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| RUN sf plugins install @salesforce/code-analyzer@${SALESFORCE_SFDX_SCANNER_VERSION} \ | ||
| && (npm cache clean --force || true) \ | ||
| && rm -rf /root/.npm/_cacache | ||
| ide: | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.