Open
Conversation
This commit adds GitHub Actions workflow for ShellCheck to lint bash scripts: - Created .github/workflows/shellcheck.yml - Runs on all pull requests and pushes - Uses ubuntu-latest where ShellCheck is pre-installed - Finds and lints all *.sh files in the repository Additionally, this commit fixes ShellCheck warnings in existing scripts: - scripts/release-notes.sh: Fixed unquoted variables, replaced expr with 0 - scripts/util.sh: Replaced backticks with $(...), fixed trap command quoting - scripts/validate-license.sh: Used mapfile for array assignment instead of command substitution All bash scripts now pass ShellCheck validation. Fixes: helm#31689
Member
|
If you could sign the DCO please |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds GitHub Actions workflow to lint bash scripts with ShellCheck.
Changes Made
1. Added ShellCheck Workflow
.github/workflows/shellcheck.yml2. Fixed ShellCheck Issues
All bash scripts now pass ShellCheck validation:
scripts/release-notes.sh
exprwith arithmetic expansion $((...))(SC2003)scripts/util.sh
scripts/validate-license.sh
Testing
All scripts pass
shellcheckvalidationNo functional changes to script behavior
Ready for CI integration
Why This Is Needed
Fixes #31689