fix View > Resources > Convert negatively affects color #1397
This file contains 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
name: check-code-format | |
on: | |
workflow_dispatch: | |
pull_request: | |
types: [opened, reopened] | |
push: | |
jobs: | |
astyle: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install Artistic Style | |
run: sudo apt-get install -y astyle grep | |
- name: Check style | |
run: | | |
results="$(astyle --project=.astylerc --dry-run --recursive "./*.cpp,*.h" | awk '/^Formatted/')" | |
if [ -z "$results" ] | |
then | |
echo "SUCCESS: All files are formatted correctly" | |
exit 0 | |
else | |
count=`wc -l <<< "$results"` | |
echo "FAILURE: $count files are formatted incorrectly" | |
echo "${results//'Formatted '/' '}" | |
exit 99 | |
fi |