-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
Add Github annotations support to all linters #39122
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
Comments
|
For |
Thank you for this issue. |
PRs are pending for reviews. Not resolved yet. |
… annotations (YaFou) This PR was merged into the 5.4 branch. Discussion ---------- [Translation] XliffLintCommand supports Github Actions annotations | Q | A | ------------- | --- | Branch? | 5.x | Bug fix? | no | New feature? | yes | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Tickets | Fix #39122 (for `lint:xliff`) | License | MIT | Doc PR | TODO <!-- Replace this notice by a short README for your feature/bugfix. This will help people understand your PR and can be used as a start for the documentation. Additionally (see https://symfony.com/releases): - Always add tests and ensure they pass. - Never break backward compatibility (see https://symfony.com/bc). - Bug fixes must be submitted against the lowest maintained branch where they apply (lowest branches are regularly merged to upper ones so they get the fixes too.) - Features and deprecations must be submitted against branch 5.x. --> Adds a format to the XLIFF linter command to print Github Actions annotations when an error occurred ([documentation](https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#setting-an-error-message)). There is a new format: `github` and the command will detect automatically the format to use in comparison with the environment. > See a workflow example: https://github.com/YaFou/symfony-39828/actions/runs/485142330 --- TODO: - [x] Test with a real project Commits ------- 8ac2b2a [Translation] XliffLintCommand supports Github Actions annotations
FWIW, I was just looking into this. I would solve this by assigning the error to the |
Description
Based on #38982, we can now iterate and add Github annotations support to all the remaining linters provided by Symfony:
lint:twig
=> [TwigBridge] LintCommand supports Github Actions annotations #39826lint:xliff
=> [Translation] XliffLintCommand supports Github Actions annotations #39828lint:container
?This one may not benefit a lot from it, as we don't have file & line info to show. Only the first error message would be shown.Additionally, the
lint:twig
andlint:xliff
commands are not provided as a standalone binary as the Yaml component does. Would it be worth adding these?Example
See #38982
The text was updated successfully, but these errors were encountered: