aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/presubmit.yml
blob: 0ab4f4f43029b1d53ec889fe825d54301d70dcd4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
name: Presubmit checks
on: [pull_request]

jobs:
  build:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v2
      - run: |  # Needed for git diff to work.
          git fetch origin master --depth 1
          git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/master

      - name: Setup python environment
        uses: actions/setup-python@v2
        with:
          python-version: 3.8

      - name: Install dependencies
        run: |
          python -m pip install --upgrade pip
          pip install -r infra/ci/requirements.txt
          pip install -r infra/build/functions/requirements.txt

      - name: Run presubmit checks
        run: python infra/presubmit.py