Skip to content

Commit

Permalink
Update the PR
Browse files Browse the repository at this point in the history
  • Loading branch information
Arya Girish K committed Nov 15, 2024
1 parent 53c752a commit e41be97
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions module-assets/ci/license_checker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,12 @@ fi

# ensure LICENSE file exists if .tf file is detected incd root directory

count=$(find . -maxdepth 1 \( -name "*.tf" -o -name "ibm_catalog.json" \) 2>/dev/null | wc -l | xargs)
var1=$(find ./*.tf 2>/dev/null | wc -l | xargs)
var2=$(find ibm_catalog.json 2>/dev/null | wc -l | xargs)
count=$((var1+var2))
if [ "$count" != 0 ]; then
if [[ ! -f "LICENSE" ]]; then
echo "Required LICENSE file is missing. Please add it and try again."
exit 1
fi
fi
fi

0 comments on commit e41be97

Please sign in to comment.