Skip to content

Commit

Permalink
Merge pull request #8 from MattLoe/feature/fix-shell-script
Browse files Browse the repository at this point in the history
Fix Script Issues
  • Loading branch information
Clint-Chester authored Dec 19, 2022
2 parents 651cccf + d9ca829 commit 45a2a59
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pmd-analyser.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# shellcheck shell=sh
#!/bin/bash

# shellcheck shell=bash

# Check whether to use latest version of PMD
if [ "$PMD_VERSION" == 'latest' ]; then
Expand Down Expand Up @@ -32,7 +34,7 @@ fi
echo "::set-output name=error-found::false"
while read -r rule; do
RULE="$(echo "$rule" | jq --raw-output '.id')"
if [[ $RULE && "$ERROR_RULES" == *"$RULE"* ]]; then
if [[ "$RULE" && "$ERROR_RULES" == *"$RULE"* ]]; then
echo "::set-output name=error-found::true"
break
fi
Expand Down

0 comments on commit 45a2a59

Please sign in to comment.