Skip to content

Commit 2f0de2d

Browse files
committed
Add CI-specific pants config file
1 parent 466ca7d commit 2f0de2d

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

.github/actions/pants-init/action.yaml

+4
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,10 @@ runs:
4343
${{ runner.os }}-pants-${{ inputs.gha-cache-key }}-${{ steps.pants-cache-commit.outputs.MERGEBASE }}
4444
${{ runner.os }}-pants-${{ inputs.gha-cache-key }}-
4545
46+
- name: Tell pants to use CI config
47+
run: |
48+
echo "PANTS_CONFIG_FILES=pants.ci.toml" >> ${GITHUB_ENV}
49+
4650
- name: Bootstrap Pants
4751
run: |
4852
./pants --version

pants.ci.toml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# This config is for CI. It extends the config in pants.toml.
2+
# See https://www.pantsbuild.org/docs/using-pants-in-ci
3+
4+
[GLOBAL]
5+
# Colors often work in CI, but the shell is usually not a TTY so Pants
6+
# doesn't attempt to use them by default.
7+
colors = true
8+
9+
[stats]
10+
# "print metrics of your cache's performance at the end of the run,
11+
# including the number of cache hits and the total time saved thanks
12+
# to caching"
13+
log = true

0 commit comments

Comments
 (0)