Skip to content

Commit 80b9a91

Browse files
hugovkdi
andauthored
CI updates (#108)
* Add button to UI to trigger workflow * Bump actions versions * Cache pip on CI * Only release for PyPA builds * Add colour to logs Co-authored-by: Dustin Ingram <[email protected]>
1 parent adb071f commit 80b9a91

File tree

2 files changed

+14
-5
lines changed

2 files changed

+14
-5
lines changed

.github/workflows/main.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,21 @@
11
name: CI
22

3-
on: [push, pull_request]
3+
on: [push, pull_request, workflow_dispatch]
4+
5+
env:
6+
FORCE_COLOR: 1
47

58
jobs:
69
build:
710
runs-on: ubuntu-latest
811
steps:
9-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v3
1013
- name: Set up Python
11-
uses: actions/setup-python@v1
14+
uses: actions/setup-python@v3
1215
with:
1316
python-version: '3.x'
17+
cache: pip
18+
cache-dependency-path: requirements/dev.txt
1419
- name: Lint
1520
run: make lint
1621
- name: Test

.github/workflows/release.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,20 @@ on:
44
push:
55
branches:
66
- main
7+
workflow_dispatch:
78

89
jobs:
910
build-and-publish:
11+
if: github.repository_owner == 'pypa'
1012
runs-on: ubuntu-latest
1113
steps:
12-
- uses: actions/checkout@v2
14+
- uses: actions/checkout@v3
1315
- name: Set up Python
14-
uses: actions/setup-python@v1
16+
uses: actions/setup-python@v3
1517
with:
1618
python-version: '3.x'
19+
cache: pip
20+
cache-dependency-path: .github/workflows/release.yml
1721
- name: Lint
1822
run: make lint
1923
- name: Test

0 commit comments

Comments
 (0)