Skip to content

Commit 7c66f45

Browse files
mmarchiniaddaleax
authored andcommitted
build: drop Travis in favor of Actions
GitHub Actions is running all tests already present on Travis, as well as building on more platforms (OS X and Windows). With Travis we're also getting timeouts more frequently than with Actions, which gives the false impression tests are failing (making it harder to triage PRs ready to merge). To make our config simpler, CI.yml and pythonpackage.yml got merged. The coverage is also increased by running tests on OS X. Signed-off-by: Matheus Marchini <[email protected]> PR-URL: #32450 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Christian Clauss <[email protected]> Reviewed-By: Jiawen Geng <[email protected]> Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: Ben Coe <[email protected]> Reviewed-By: Tobias Nießen <[email protected]> Reviewed-By: Michaël Zasso <[email protected]>
1 parent ca19d55 commit 7c66f45

11 files changed

+167
-212
lines changed

.github/workflows/CI.yml

-79
This file was deleted.

.github/workflows/build-windows.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: build-windows
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
PYTHON_VERSION: 3.8
7+
FLAKY_TESTS: dontcare
8+
9+
jobs:
10+
build-windows:
11+
runs-on: windows-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set up Python ${{ env.PYTHON_VERSION }}
15+
uses: actions/setup-python@v1
16+
with:
17+
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
18+
- name: Install deps
19+
run: choco install nasm
20+
- name: Environment Information
21+
run: npx envinfo
22+
- name: Build
23+
run: ./vcbuild.bat

.github/workflows/linters.yml

+73
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: linters
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
PYTHON_VERSION: 3.8
7+
NODE_VERSION: 10.x
8+
9+
jobs:
10+
lint-addon-docs:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Use Node.js ${{ env.NODE_VERSION }}
15+
uses: actions/setup-node@v1
16+
with:
17+
node-version: ${{ env.NODE_VERSION }}
18+
- name: Environment Information
19+
run: npx envinfo
20+
- name: Lint addon docs
21+
run: NODE=$(which node) make lint-addon-docs
22+
lint-cpp:
23+
runs-on: ubuntu-latest
24+
steps:
25+
- uses: actions/checkout@v2
26+
- name: Set up Python ${{ env.PYTHON_VERSION }}
27+
uses: actions/setup-python@v1
28+
with:
29+
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
30+
- name: Environment Information
31+
run: npx envinfo
32+
- name: Lint C/C++ files
33+
run: make lint-cpp
34+
lint-md:
35+
runs-on: ubuntu-latest
36+
steps:
37+
- uses: actions/checkout@v2
38+
- name: Use Node.js ${{ env.NODE_VERSION }}
39+
uses: actions/setup-node@v1
40+
with:
41+
node-version: ${{ env.NODE_VERSION }}
42+
- name: Environment Information
43+
run: npx envinfo
44+
- name: Lint docs
45+
run: |
46+
echo "::add-matcher::.github/workflows/remark-lint-problem-matcher.json"
47+
NODE=$(which node) make lint-md
48+
lint-js:
49+
runs-on: ubuntu-latest
50+
steps:
51+
- uses: actions/checkout@v2
52+
- name: Use Node.js ${{ env.NODE_VERSION }}
53+
uses: actions/setup-node@v1
54+
with:
55+
node-version: ${{ env.NODE_VERSION }}
56+
- name: Environment Information
57+
run: npx envinfo
58+
- name: Lint JavaScript files
59+
run: NODE=$(which node) make lint-js
60+
lint-py:
61+
runs-on: ubuntu-latest
62+
steps:
63+
- uses: actions/checkout@v2
64+
- name: Set up Python ${{ env.PYTHON_VERSION }}
65+
uses: actions/setup-python@v1
66+
with:
67+
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
68+
- name: Environment Information
69+
run: npx envinfo
70+
- name: Lint Python
71+
run: |
72+
make lint-py-build || true
73+
NODE=$(which node) make lint lint-py

.github/workflows/misc.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: misc
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
NODE_VERSION: 12.x
7+
8+
jobs:
9+
build-docs:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- name: Use Node.js ${{ env.NODE_VERSION }}
14+
uses: actions/setup-node@v1
15+
with:
16+
node-version: ${{ env.NODE_VERSION }}
17+
- name: Environment Information
18+
run: npx envinfo
19+
- name: Build
20+
run: NODE=$(which node) make doc-only
21+
- uses: actions/upload-artifact@v1
22+
with:
23+
name: docs
24+
path: out/doc

.github/workflows/pythonpackage.yml

-33
This file was deleted.

.github/workflows/test-linux.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: test-linux
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
PYTHON_VERSION: 3.8
7+
FLAKY_TESTS: dontcare
8+
9+
jobs:
10+
test-linux:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set up Python ${{ env.PYTHON_VERSION }}
15+
uses: actions/setup-python@v1
16+
with:
17+
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
18+
- name: Environment Information
19+
run: npx envinfo
20+
- name: Build
21+
run: make build-ci -j2 V=1
22+
- name: Test
23+
run: make run-ci -j2 V=1

.github/workflows/test-macos.yml

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: test-macOS
2+
3+
on: [push, pull_request]
4+
5+
env:
6+
PYTHON_VERSION: 3.8
7+
FLAKY_TESTS: dontcare
8+
9+
jobs:
10+
test-macOS:
11+
runs-on: macos-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set up Python ${{ env.PYTHON_VERSION }}
15+
uses: actions/setup-python@v1
16+
with:
17+
PYTHON_VERSION: ${{ env.PYTHON_VERSION }}
18+
- name: Environment Information
19+
run: npx envinfo
20+
- name: Build
21+
run: make build-ci -j8 V=1
22+
- name: Test
23+
run: make run-ci -j8 V=1

.gitignore

-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
!.gitkeep
2020
!.mailmap
2121
!.nycrc
22-
!.travis.yml
2322
!.eslintrc.yaml
2423
!.cpplint
2524

.travis.yml

-88
This file was deleted.

configure

-3
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,7 @@
33
# Locate an acceptable python interpreter and then re-execute the script.
44
# Note that the mix of single and double quotes is intentional,
55
# as is the fact that the ] goes on a new line.
6-
# When a 'which' call is made for a specific version of Python on Travis CI,
7-
# pyenv will alert which shims are available and then will fail the build.
86
_=[ 'exec' '/bin/sh' '-c' '''
9-
test ${TRAVIS} && exec python "$0" "$@" # workaround for pyenv on Travis CI
107
test ${FORCE_PYTHON2} && exec python2 "$0" "$@" # workaround for gclient
118
which python3.8 >/dev/null && exec python3.8 "$0" "$@"
129
which python3.7 >/dev/null && exec python3.7 "$0" "$@"

0 commit comments

Comments
 (0)