Skip to content

Conversation

@ldez
Copy link
Member

@ldez ldez commented May 1, 2024

Currently, when running the GitHub Action each annotation creates 2 outputs:

  • a "popup"
  • a log

The "popup" works well but the log doesn't display the file information (path, position).

The default annotations format ::error file={name},line={line},col={endLine}::{message} doesn't display the file information (I don't know why).

This PR uses a specific feature called "Problem Matchers" that allows defining a custom format.
With this custom format, the log displays file information.

Screenshot log

Screenshot popup summary

Screenshot popup code

Fixes golangci/golangci-lint-action#119

@ldez ldez added enhancement New feature or improvement area: output Related to issue output labels May 1, 2024
@ldez ldez added this to the next milestone May 1, 2024
Copy link
Member

@bombsimon bombsimon left a comment

Choose a reason for hiding this comment

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

💯

ldez and others added 2 commits May 2, 2024 22:38
@ldez ldez merged commit 28b3813 into golangci:master May 2, 2024
@ldez ldez deleted the feat/github-action-format branch May 2, 2024 20:58
@ldez ldez modified the milestones: next, v1.58 May 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: output Related to issue output enhancement New feature or improvement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

github action log output doesn't print the affected file name & line

2 participants