Split out font code into sindarin-inc/tiny-font (#1151) #4524
This file contains hidden or 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: Run Clang Tools | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| clangify: | |
| runs-on: | |
| group: Beefy | |
| container: | |
| image: espressif/idf:v5.3.2 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| repository: ${{ github.event.pull_request.head.repo.full_name }} | |
| ref: ${{ github.event.pull_request.head.ref }} | |
| submodules: "recursive" | |
| - name: Install tools | |
| run: | | |
| . $IDF_PATH/export.sh | |
| idf_tools.py install esp-clang | |
| pip install --upgrade pyclang | |
| # See https://github.com/actions/checkout/issues/1169 | |
| - run: git config --system --add safe.directory /__w/embedded-app/embedded-app | |
| if: github.event_name == 'pull_request' | |
| - name: Run clang-tidy | |
| run: | | |
| . $IDF_PATH/export.sh | |
| make clang-tidy | |
| - name: Post errors and warnings as annotations | |
| if: github.event_name == 'pull_request' && (success() || failure()) | |
| run: | | |
| . $IDF_PATH/export.sh | |
| pip install requests curlify | |
| python scripts/parse_warnings.py --filename warnings.txt --title clang-tidy --path_prefix "/__w/embedded-app/embedded-app/" | |
| env: | |
| PR_GITHUB_SHA: ${{ github.event.pull_request.head.sha || github.sha }} | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Run clang-format | |
| run: | | |
| . $IDF_PATH/export.sh | |
| make clang-format | |
| - name: "Commit changes if necessary" | |
| if: github.event_name == 'pull_request' | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| git fetch origin ${{ github.head_ref }} | |
| echo "HEAD: $(git rev-parse HEAD)" | |
| echo "UPSTREAM: $(git rev-parse @{u})" | |
| if [ "$(git rev-parse HEAD)" != "$(git rev-parse @{u})" ]; then | |
| echo "Newer changes detected on branch. Skipping commit." | |
| exit 0 | |
| fi | |
| if git diff --exit-code 'src/*/*.hpp' 'src/*/*.h' 'src/*/*.cpp' 'src/*/*.c' > /dev/null; then | |
| echo "No changes to commit" | |
| else | |
| git config --global user.name "Clang Robot" | |
| git config --global user.email "robot@sindarin.com" | |
| git add 'src/*/*.hpp' 'src/*/*.h' 'src/*/*.cpp' 'src/*/*.c' | |
| git commit -m "Committing clang-format/clang-tidy changes" | |
| git push origin HEAD:${{ github.head_ref }} | |
| fi |