Skip to content

Commit

Permalink
Update format check.
Browse files Browse the repository at this point in the history
  • Loading branch information
marianabuhazi committed May 7, 2024
1 parent 9266515 commit cba559e
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions .github/workflows/regression-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,14 @@ jobs:
. ~/.bashrc
- name: Run code formatting check
run: |
chmod +x $GITHUB_WORKSPACE/utils/scripts/actions-pipeline/code-format/format_modified.sh
if ! $GITHUB_WORKSPACE/utils/scripts/actions-pipeline/code-format/format_modified.sh -g -ca; then
echo "Code format check failed. Please fix the formatting issues by running the following script: /utils/scripts/format_modified.sh"
exit 1
cd $GITHUB_WORKSPACE/utils/scripts/actions-pipeline/code-format/
chmod +x format_modified.sh
if [ -n "$(git rev-parse --show-toplevel 2>/dev/null)" ]; then
if ! ./format_modified.sh -g -ca; then
echo "Code format check failed. Please fix the formatting issues by running the following script: /utils/scripts/format_modified.sh"
exit 1
fi
else
echo "Not in a Git repository. Skipping code formatting check."
fi

0 comments on commit cba559e

Please sign in to comment.