Skip to content

detektVersionReplace.js plugin is not replacing all [detekt_version] tags on website#5266

Merged
BraisGabin merged 1 commit into
detekt:mainfrom
Ridje:patch-1
Sep 4, 2022
Merged

detektVersionReplace.js plugin is not replacing all [detekt_version] tags on website#5266
BraisGabin merged 1 commit into
detekt:mainfrom
Ridje:patch-1

Conversation

@Ridje
Copy link
Copy Markdown
Contributor

@Ridje Ridje commented Sep 1, 2022

There is error on cli guide installation page.

Instead of

curl -sSLO https://github.com/detekt/detekt/releases/download/v1.21.0/detekt-cli-1.21.0.zip
unzip detekt-cli-1.21.0.zip
./detekt-cli-1.21.0/bin/detekt-cli --help

the block Any OS is showing next command:

curl -sSLO https://github.com/detekt/detekt/releases/download/v1.21.0/detekt-cli-[detekt_version].zip
unzip detekt-cli-[detekt_version].zip
./detekt-cli-[detekt_version]/bin/detekt-cli --help

I suppose this issue is happening because detektVersionReplace.js plugin uses 'replace' in node instead of 'replaceAll'.
Or I can also suggest to use do while instead of if block.

There is error on https://detekt.dev/docs/gettingstarted/cli/ page.

instead of `curl -sSLO https://github.com/detekt/detekt/releases/download/v1.21.0/detekt-cli-1.21.0.zip
unzip detekt-cli-1.21.0.zip
./detekt-cli-1.21.0/bin/detekt-cli --help` it shows 'curl -sSLO https://github.com/detekt/detekt/releases/download/v1.21.0/detekt-cli-[detekt_version].zip
unzip detekt-cli-[detekt_version].zip
./detekt-cli-[detekt_version]/bin/detekt-cli --help' command.
I suppose this issue is happening because detekt plugin uses 'replace' in node instead of 'replaceAll'.
Or I can also suggest to use `do while` instead of `if` block.
Copy link
Copy Markdown
Member

@schalkms schalkms left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@schalkms schalkms added this to the 1.22.0 milestone Sep 4, 2022
Copy link
Copy Markdown
Member

@BraisGabin BraisGabin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much! :)

@BraisGabin BraisGabin merged commit 361eb57 into detekt:main Sep 4, 2022
@Ridje Ridje deleted the patch-1 branch September 5, 2022 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants