Compare commits
1 commit
d961620bcf
...
eb1e69b49c
Author | SHA1 | Date | |
---|---|---|---|
|
eb1e69b49c |
|
@ -24,12 +24,23 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
apt-get update && apt-get install -y shellcheck
|
apt-get update && apt-get install -y shellcheck
|
||||||
|
|
||||||
- name: Run ShellCheck
|
- name: Find Shell Scripts
|
||||||
shell: bash
|
id: find-scripts
|
||||||
run: |
|
run: |
|
||||||
echo "Searching for shell scripts..."
|
echo "Searching for shell scripts..."
|
||||||
find . -name '*.sh' -print0 > shell-scripts.list
|
find . -name '*.sh' > shell-scripts.list
|
||||||
|
echo "Found the following scripts:"
|
||||||
|
cat shell-scripts.list
|
||||||
|
|
||||||
|
- name: Run ShellCheck in Script Directories
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
echo "Running ShellCheck in each script's directory..."
|
echo "Running ShellCheck in each script's directory..."
|
||||||
|
if [ ! -s shell-scripts.list ]; then
|
||||||
|
echo "No shell scripts found."
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
while IFS= read -r script; do
|
while IFS= read -r script; do
|
||||||
echo "Checking $script"
|
echo "Checking $script"
|
||||||
script_dir=$(dirname "$script")
|
script_dir=$(dirname "$script")
|
||||||
|
|
Loading…
Reference in a new issue