• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1name: Presubmit checks
2
3on:
4  pull_request:
5    branches:
6    - master
7
8jobs:
9  build:
10    runs-on: ubuntu-latest
11
12    steps:
13      - name: Cancel previous
14        uses: styfle/cancel-workflow-action@0.8.0
15        with:
16          access_token: ${{ github.token }}
17
18      - uses: actions/checkout@v2
19        with:  # Needed for git diff to work. (get_changed_files)
20          fetch-depth: 0
21      - run: |
22          git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/master
23
24      - name: Setup python environment
25        uses: actions/setup-python@v2
26        with:
27          python-version: 3.8
28
29      - name: Install dependencies
30        run: |
31          python -m pip install --upgrade pip
32          pip install -r infra/ci/requirements.txt
33          pip install -r infra/build/functions/requirements.txt
34
35      - name: Run presubmit checks
36        run: python infra/presubmit.py
37