-
Notifications
You must be signed in to change notification settings - Fork 76
62 lines (62 loc) · 1.72 KB
/
push.yml
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: 'Continuous Integration'
on: [push, pull_request]
jobs:
unit-tests:
runs-on: '${{ matrix.os }}'
continue-on-error: ${{ matrix.status != 'current' }}
strategy:
fail-fast: false
matrix:
status: ['current']
os:
- ubuntu-20.04
node-version:
- 12.x
- 14.x
- 16.x
- 18.x
- 20.x
include:
- os: ubuntu-20.04
node-version: 8.x
status: 'deprecated'
- os: ubuntu-20.04
node-version: 10.x
status: 'deprecated'
steps:
- uses: actions/checkout@v3
- name: 'Install apt packages'
shell: bash
run: |
sudo apt-get update
sudo apt-get install build-essential curl autoconf automake libtool pkg-config
- name: 'Create working directories'
shell: bash
run: |
sudo mkdir -p /code /data /deps
sudo chown $USER:$USER /code /data /deps
- name: 'Install libpostal'
shell: bash
run: |
cd /code
git clone https://github.com/openvenues/libpostal
cd libpostal
./bootstrap.sh
./configure --datadir=/data --prefix=/deps --bindir=/deps || cat config.log
make -j4
make install
- name: 'Install node.js ${{ matrix.node-version }}'
uses: actions/setup-node@v2-beta
with:
node-version: '${{ matrix.node-version }}'
- name: 'Install node-postal'
env:
CXXFLAGS: '-I/deps/include'
LDFLAGS: '-L/deps/lib'
run:
npm install
- name: 'Run unit tests'
env:
LD_LIBRARY_PATH: '/deps/lib'
run: |
npm test