Skip to content

docs: update migration guide with --print-issued-lines #5886

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

Merged
merged 3 commits into from
Jun 20, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 33 additions & 1 deletion docs/src/docs/product/migration-guide.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2070,6 +2070,8 @@ The following flags have been removed:
- `--sort-order`
- `--sort-results`
- `--out-format`
- `--print-issued-lines`
- `--print-linter-name`

#### `--out-format`

Expand Down Expand Up @@ -2126,13 +2128,23 @@ The following flags have been removed:
--output.sarif.path
```

#### `--print-issued-lines`

`--print-issued-lines` has been replaced with `--output.text.print-issued-lines`.

#### `--print-linter-name`

`--print-linter-name` has been replaced with `--output.text.print-linter-name` or `--output.tab.print-linter-name`.

#### `--disable-all` and `--enable-all`

`--disable-all` has been replaced with `--default=none`.

`--enable-all` has been replaced with `--default=all`.

#### Example
#### Examples

Run only the `govet` linter, output results to stdout in JSON format, and sort results:

<details>
<summary style={{color: '#737380', paddingLeft: '1rem'}}>v1</summary>
Expand All @@ -2151,3 +2163,23 @@ golangci-lint run --default=none --enable=govet --output.json.path=stdout
```

</details>

Do not print issued lines, output results to stdout without colors in text format, and to `gl-code-quality-report.json` file in Code Climate's format:

<details>
<summary style={{color: '#737380', paddingLeft: '1rem'}}>v1</summary>

```bash
golangci-lint run --print-issued-lines=false --out-format code-climate:gl-code-quality-report.json,line-number
```

</details>

<details>
<summary style={{color: '#737380', paddingLeft: '1rem'}}>v2</summary>

```bash
golangci-lint run --output.text.path=stdout --output.text.colors=false --output.text.print-issued-lines=false --output.code-climate.path=gl-code-quality-report.json
```

</details>
Loading