Ft remove logging and directly visualize #69
Workflow file for this run
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: Linter | |
on: | |
pull_request: | |
branches: [ "main" ] | |
types: [opened, labeled, unlabeled, synchronize] | |
jobs: | |
format: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
token: ${{ secrets.BOT_TOKEN }} | |
# check out HEAD on the branch | |
ref: ${{ github.head_ref }} | |
# make sure the parent commit is grabbed as well, because | |
# that's what will get formatted (i.e. the most recent commit) | |
fetch-depth: 2 | |
- name: Install clang-format | |
run: | | |
sudo apt-get install -y clang-format | |
- name: Run clang-format | |
run: | | |
# run clang-format on all files in the repo | |
# (except for the .git and .vscode directory) and use .clang-format | |
# as the style guide | |
find . -not -path "./.git/*" -not -path "./.vscode/*" -name "*.cpp" -o -name "*.h" | xargs clang-format -i -style=file | |
# commit the changes (if there are any) | |
- name: Commit changes | |
uses: stefanzweifel/[email protected] | |
with: | |
commit_message: 🎨 apply clang-format changes | |
branch: ${{ github.head_ref }} | |