Skip to content

Commit

Permalink
Fix incorrect version numbers in documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-dingemans committed Sep 17, 2023
1 parent 288dea0 commit afe88df
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 16 deletions.
4 changes: 2 additions & 2 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ Note: These steps should be done directly in the pinterest/ktlint repository, no
5. Add the new release to the bottom of the `CHANGELOG.md` file.
6. Push your changes to the branch, and merge it to `master`.
7. Update your local `pinterest/ktlint` `master` branch; verify you see the `gradle.properties` and `CHANGELOG.md` changes locally.
8. Add a tag with the new release version, and push it directly to remote (e.g. `git tag 0.50.0 && git push origin 0.50.0`). This will kick off the [Release workflow](https://github.com/pinterest/ktlint/actions/workflows/release.yml).Important: when you get an error like `HttpError: refusing to allow a Personal Access Token to create or update workflow '.github/workflows/automerge-triggers.yml' without 'workflow' scope`, the Github personal access token is most likely expired. When this happens on the bump of the Homebrew formula, the personal access token of @shashachu needs to be updated.
8. Add a tag with the new release version, and push it directly to remote (e.g. `git tag 0.50.0 && git push origin 0.50.0`). This will kick off the [Release workflow](https://github.com/pinterest/ktlint/actions/workflows/release.yml).Important: when you get an error like `HttpError: refusing to allow a Personal Access Token to create or update workflow '.github/workflows/automerge-triggers.yml' without 'workflow' scope`, the GitHub personal access token is most likely expired. When this happens on the bump of the Homebrew formula, the personal access token of @shashachu needs to be updated.
9. Close and release the repo on Sonatype. Only Pinterest employees can do this. Wait with steps below until artifacts are published on https://central.sonatype.com/search?q=ktlint&sort=published
10. The `.announce` script has created the `<release>-update-refs` branch in the repo. Create a new pull request (https://github.com/pinterest/ktlint/compare) and merge it to master.
11. Merge of branch `<release>-update-refs` to master starts the `Publish release documentation` and `Publish snapshot documentation` workflows. Check that both workflows succeed (https://github.com/pinterest/ktlint/actions). Also check that the documentation has actually been published on https://pinterest.github.io/ktlint/latest.
12. Verify that documentation of new release is published correctly.
12. Verify that documentation of new release is published correctly. Especially check whether version numbers in [documentation](https://pinterest.github.io/ktlint/latest/install/cli/) have been changed. After publication of `1.0.0` the documentation still referred to `0.50.0` (according to https://github.com/pinterest/ktlint/actions/runs/6085301212/job/16509057702#step:11:14 it tried updating `0.49.1` to `1.0.0` which most likely was caused by the already fixed issue that the changelog heading of the `0.50.0` did not comply to the expected format).
13. Verify that the published documentation does not contain broken links with [Broken Link Checker Tool](https://www.deadlinkchecker.com/website-dead-link-checker.asp).
14. Announce release on Ktlint Slack channel
15. Update `gradle.properties` with the new `SNAPSHOT` version, and add the section below to the top of `CHANGELOG.md` and commit. (This can be done directly in the main repo or in your fork.)
Expand Down
4 changes: 2 additions & 2 deletions documentation/release-latest/docs/install/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ All releases of `ktlint` can be downloaded from the [releases](https://github.co
A particular version of `ktlint` can be downloaded with next command which also changes the file to an executable in directory `/usr/local/bin`:

```sh title="Download"
curl -sSLO https://github.com/pinterest/ktlint/releases/download/0.50.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.0.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
```

!!! tip "Curl not installed or behind proxy"
Expand Down Expand Up @@ -218,6 +218,6 @@ Options `--stdin` and `--patterns-from-stdin` are mutually exclusive, only one o

Microsoft Windows is not able to run the `ktlint` command directly. Ktlint can be run in following ways on Microsoft Windows:

1. Use the `ktlint.bat` batch file provided as part of the [release](https://github.com/pinterest/ktlint/releases/tag/0.50.0). Add the batch file to your `%PATH%` environment variable for easy access
1. Use the `ktlint.bat` batch file provided as part of the [release](https://github.com/pinterest/ktlint/releases/tag/1.0.0). Add the batch file to your `%PATH%` environment variable for easy access
2. Run `ktlint` using Git Bash
3. Run as `java -jar ktlint`
10 changes: 5 additions & 5 deletions documentation/release-latest/docs/install/integrations.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ See [cli usage](../cli) for arguments that can be supplied to `ktlint`.
</executions>
<dependencies>
<dependency>
<groupId>com.pinterest</groupId>
<artifactId>ktlint</artifactId>
<version>0.50.0</version>
<groupId>com.pinterest.ktlint</groupId>
<artifactId>ktlint-cli</artifactId>
<version>1.0.0</version>
</dependency>
<!-- additional 3rd party ruleset(s) can be specified here -->
</dependencies>
Expand Down Expand Up @@ -117,7 +117,7 @@ configurations {
}
dependencies {
ktlint("com.pinterest:ktlint:0.50.0") {
ktlint("com.pinterest.ktlint:ktlint-cli:1.0.0") {
attributes {
attribute(Bundling.BUNDLING_ATTRIBUTE, getObjects().named(Bundling, Bundling.EXTERNAL))
}
Expand Down Expand Up @@ -167,7 +167,7 @@ The configuration below, defines following task:
val ktlint by configurations.creating

dependencies {
ktlint("com.pinterest:ktlint:0.50.0") {
ktlint("com.pinterest.ktlint:ktlint-cli:1.0.0") {
attributes {
attribute(Bundling.BUNDLING_ATTRIBUTE, objects.named(Bundling.EXTERNAL))
}
Expand Down
4 changes: 2 additions & 2 deletions documentation/snapshot/docs/install/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ All releases of `ktlint` can be downloaded from the [releases](https://github.co
A particular version of `ktlint` can be downloaded with next command which also changes the file to an executable in directory `/usr/local/bin`:

```sh title="Download"
curl -sSLO https://github.com/pinterest/ktlint/releases/download/0.50.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
curl -sSLO https://github.com/pinterest/ktlint/releases/download/1.0.0/ktlint && chmod a+x ktlint && sudo mv ktlint /usr/local/bin/
```

!!! tip "Curl not installed or behind proxy"
Expand Down Expand Up @@ -210,6 +210,6 @@ Options `--stdin` and `--patterns-from-stdin` are mutually exclusive, only one o

Microsoft Windows is not able to run the `ktlint` command directly. Ktlint can be run in following ways on Microsoft Windows:

1. Use the `ktlint.bat` batch file provided as part of the [release](https://github.com/pinterest/ktlint/releases/tag/0.50.0). Add the batch file to your `%PATH%` environment variable for easy access
1. Use the `ktlint.bat` batch file provided as part of the [release](https://github.com/pinterest/ktlint/releases/tag/1.0.0). Add the batch file to your `%PATH%` environment variable for easy access
2. Run `ktlint` using Git Bash
3. Run as `java -jar ktlint`
10 changes: 5 additions & 5 deletions documentation/snapshot/docs/install/integrations.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ See [cli usage](../cli) for arguments that can be supplied to `ktlint`.
</executions>
<dependencies>
<dependency>
<groupId>com.pinterest</groupId>
<artifactId>ktlint</artifactId>
<version>0.50.0</version>
<groupId>com.pinterest.ktlint</groupId>
<artifactId>ktlint-cli</artifactId>
<version>1.0.0</version>
</dependency>
<!-- additional 3rd party ruleset(s) can be specified here -->
</dependencies>
Expand Down Expand Up @@ -117,7 +117,7 @@ configurations {
}
dependencies {
ktlint("com.pinterest:ktlint:0.50.0") {
ktlint("com.pinterest.ktlint:ktlint-cli:1.0.0") {
attributes {
attribute(Bundling.BUNDLING_ATTRIBUTE, getObjects().named(Bundling, Bundling.EXTERNAL))
}
Expand Down Expand Up @@ -167,7 +167,7 @@ The configuration below, defines following task:
val ktlint by configurations.creating

dependencies {
ktlint("com.pinterest:ktlint:0.50.0") {
ktlint("com.pinterest.ktlint:ktlint-cli:1.0.0") {
attributes {
attribute(Bundling.BUNDLING_ATTRIBUTE, objects.named(Bundling.EXTERNAL))
}
Expand Down

0 comments on commit afe88df

Please sign in to comment.