vale-at-red-hat icon indicating copy to clipboard operation
vale-at-red-hat copied to clipboard

ci(lint): add shell linter - Differential ShellCheck

Open jamacku opened this issue 1 year ago • 5 comments

Description

Addition of a new job in CI workflow that scans all shell scripts in the repo using ShellCheck and reports only newly added defects.

Differential ShellCheck is a GitHub action that performs differential ShellCheck scans on shell scripts changed via PR and reports results directly in PR.

It produces reports in SARIF format. GitHub understands this format and is able to display it nicely as a PR comment, and on the Files Changed tab, please see below.

Documentation is available at @redhat-plumbers-in-action/differential-shellcheck.

Screenshots

image

image

jamacku avatar Apr 21 '24 05:04 jamacku

Click here to review and test in web IDE: Contribute

github-actions[bot] avatar Apr 21 '24 05:04 github-actions[bot]

⚡️ Deploying PR Preview...

github-actions[bot] avatar Apr 21 '24 05:04 github-actions[bot]

Thanks for the PR. Any particular reason why you are targeting this repo with this update? You've not contributed here before.

aireilly avatar Apr 22 '24 09:04 aireilly

I just came across your org and this repo, and I noticed that you have some shell scripts and don't run ShellCheck in your CI.

jamacku avatar Apr 22 '24 10:04 jamacku

This pull request sets up GitHub code scanning for this repository. Once the scans have completed and the checks have passed, the analysis results for this pull request branch will appear on this overview. Once you merge this pull request, the 'Security' tab will show more code scanning analysis results (for example, for the default branch). Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results. For more information about GitHub code scanning, check out the documentation.

Seems a duplicate with https://github.com/redhat-documentation/vale-at-red-hat/blob/main/.github/workflows/validate-scripts.yml

themr0c avatar Jun 10 '24 11:06 themr0c

Not required

aireilly avatar Jun 19 '24 12:06 aireilly