Skip to content

Commit dbaf2ef

Browse files
authored
Merge pull request #151 from line-o/feat/switch-to-gha
Switch CI to GitHub actions
2 parents 6f91d8c + a19a203 commit dbaf2ef

9 files changed

+1154
-2651
lines changed

.github/workflows/release.yml

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: Release npm package
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
release:
10+
name: Release
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@master
14+
- uses: actions/setup-node@v1
15+
with:
16+
node-version: "14.x"
17+
18+
- name: npm install and build
19+
run:
20+
npm ci
21+
22+
- name: Pull docker image
23+
run: docker pull existdb/existdb:release
24+
25+
- name: Build docker image
26+
run: docker create --name exist-ci -p 8080:8080 -p 8443:8443 existdb/existdb:release
27+
28+
- name: Start docker image
29+
run: docker start exist-ci
30+
31+
- name: Wait for existdb startup
32+
run: sleep 30
33+
34+
- run: npm test
35+
- run: npx semantic-release
36+
env:
37+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
38+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/test.yml

+47
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: test node-exist
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- master
7+
8+
push:
9+
branches:
10+
- master
11+
12+
workflow_dispatch:
13+
14+
jobs:
15+
build:
16+
runs-on: ${{ matrix.os }}
17+
strategy:
18+
matrix:
19+
os: [ubuntu-latest, windows-latest]
20+
node-version: [10.x, 12.x, 14.x]
21+
docker-tag: [latest, release, 4.7.1]
22+
23+
steps:
24+
- uses: actions/checkout@v2
25+
26+
- name: Use Node.js ${{ matrix.node-version }}
27+
uses: actions/setup-node@v1
28+
with:
29+
node-version: ${{ matrix.node-version }}
30+
31+
- name: npm install and build
32+
run: npm ci
33+
34+
- name: Pull docker image
35+
run: docker pull existdb/existdb:${{ matrix.docker-tag }}
36+
37+
- name: Build docker image
38+
run: docker create --name exist-ci -p 8080:8080 -p 8443:8443 existdb/existdb:${{ matrix.docker-tag }}
39+
40+
- name: Start docker image
41+
run: docker start exist-ci
42+
43+
- name: Wait for existdb startup
44+
run: sleep 20
45+
46+
- name: npm test
47+
run: npm test

.releaserc

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"plugins": [
3+
"@semantic-release/commit-analyzer",
4+
"@semantic-release/release-notes-generator",
5+
"@semantic-release/npm",
6+
"@semantic-release/github",
7+
]
8+
}

.travis.yml

-53
This file was deleted.

appveyor.yml

-25
This file was deleted.

ci/setup.ps1

-28
This file was deleted.

ci/teardown.ps1

-10
This file was deleted.

0 commit comments

Comments
 (0)