File tree 6 files changed +21
-547
lines changed
6 files changed +21
-547
lines changed Original file line number Diff line number Diff line change @@ -24,14 +24,16 @@ jobs:
24
24
python-version : [3.8]
25
25
steps :
26
26
- uses : actions/checkout@v3
27
- - uses : pantsbuild/actions/init-pants@v2
27
+ - uses : actions/setup-python@v4
28
+ with :
29
+ python-version : ${{ matrix.python-version }}
30
+ - uses : pantsbuild/actions/init-pants@v4-scie-pants
28
31
# This action bootstraps pants and manages 2-3 GHA caches.
29
32
# See: github.com/pantsbuild/actions/tree/main/init-pants/
30
33
with :
31
- pants-python-version : ${{ matrix.python-version }}
32
- # cache0 makes it easy to bust the cache if needed
34
+ # v0 makes it easy to bust the cache if needed
33
35
# just increase the integer to start with a fresh cache
34
- gha-cache-key : cache0-py${{ matrix.python-version }}
36
+ gha-cache-key : v0
35
37
# The Python backend uses named_caches for Pip/PEX state,
36
38
# so it is appropriate to invalidate on lockfile changes.
37
39
named-caches-hash : ${{ hashFiles('python-default.lock') }}
@@ -53,12 +55,12 @@ jobs:
53
55
echo "PATH=${PATH}:${HOME}/.thrift" >> $GITHUB_ENV
54
56
- name : Bootstrap Pants
55
57
run : |
56
- ./ pants --version
58
+ pants --version
57
59
- name : Check BUILD files
58
- run : ./ pants tailor --check update-build-files --check
60
+ run : pants tailor --check update-build-files --check
59
61
- name : Lint and test
60
62
run : |
61
- ./ pants lint test ::
63
+ pants lint test ::
62
64
- name : Upload Pants log
63
65
uses : actions/upload-artifact@v3
64
66
with :
Original file line number Diff line number Diff line change 1
1
// This lockfile was autogenerated by Pants. To regenerate, run:
2
2
//
3
- // ./ pants generate-lockfiles --resolve=python-default
3
+ // pants generate-lockfiles --resolve=python-default
4
4
//
5
5
// --- BEGIN PANTS LOCKFILE METADATA: DO NOT EDIT OR REMOVE ---
6
6
// {
Original file line number Diff line number Diff line change 2
2
3
3
An example repository to demonstrate codegen support in Pants.
4
4
5
+ You run Pants goals using the ` pants ` launcher binary, which will bootstrap the
6
+ version of Pants configured for this repo if necessary.
7
+
8
+ See [ here] ( https://www.pantsbuild.org/docs/installation ) for how to install the ` pants ` binary.
9
+
5
10
Refer to these docs for more information:
6
11
7
12
* [ Go Protobuf] ( https://www.pantsbuild.org/docs/protobuf-go )
@@ -10,13 +15,13 @@ Refer to these docs for more information:
10
15
11
16
Some commands you can try out:
12
17
13
- * ` ./ pants export-codegen ::` - see the generated files.
18
+ * ` pants export-codegen :: ` - see the generated files.
14
19
* This isn't necessary for Pants to use the generated files, but can be useful when
15
20
debugging or to generate files for IDEs.
16
- * ` ./ pants test ::` - run all tests
17
- * ` ./ pants fmt ::` - format Protobuf with ` buf `
18
- * ` ./ pants lint ::` - lint Protobuf with ` buf `
19
- * ` ./ pants dependencies <path/to/file>` - see what depends on what
21
+ * ` pants test :: ` - run all tests
22
+ * ` pants fmt :: ` - format Protobuf with ` buf `
23
+ * ` pants lint :: ` - lint Protobuf with ` buf `
24
+ * ` pants dependencies <path/to/file> ` - see what depends on what
20
25
21
26
Check out our other [ example repositories] ( https://www.pantsbuild.org/docs/example-repos ) to see
22
27
other features like packaging binaries.
You can’t perform that action at this time.
0 commit comments