[build] Split Actions into different yml files (#3025)

This commit is contained in:
Austin Shalit
2020-12-31 20:33:39 -08:00
committed by GitHub
parent 948af6d5b5
commit 26d0004fe1
4 changed files with 102 additions and 90 deletions

27
.github/workflows/lint-format.yml vendored Normal file
View File

@@ -0,0 +1,27 @@
name: Lint and Format
on: [pull_request, push]
jobs:
wpiformat:
name: "wpiformat"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Fetch all history and metadata
run: |
git fetch --prune --unshallow
git checkout -b pr
git branch -f master origin/master
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install clang-format
run: sudo apt-get update -q && sudo apt-get install clang-format-10
- name: Install wpiformat
run: pip3 install wpiformat
- name: Run
run: wpiformat -clang 10
- name: Check Output
run: git --no-pager diff --exit-code HEAD