forked from pantsbuild/example-python
-
Notifications
You must be signed in to change notification settings - Fork 0
48 lines (44 loc) · 1.16 KB
/
Copy pathpants.yaml
File metadata and controls
48 lines (44 loc) · 1.16 KB
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# Copyright 2020 Pants project contributors.
# Licensed under the Apache License, Version 2.0 (see LICENSE).
# See https://pants.readme.io/docs/using-pants-in-ci for tips on how to set up your CI with Pants.
name: Pants
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
env:
PANTS_CONFIG_FILES: pants.ci.toml
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.7]
steps:
- uses: actions/checkout@v2
- uses: actions/cache@v2
id: cache
with:
path: |
~/.cache/pants/setup
~/.cache/pants/lmdb_store
key: ${{ runner.os }}-
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: bootstrap
run: |
./pants --version
- name: Lint
run: |
./pants lint typecheck ::
- name: Test
run: |
./pants test ::
- name: Package / Run
run: |
# We also smoke test that our release process will work by running `package`.
./pants package ::
./pants run helloworld/main.py