-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (52 loc) · 1.38 KB
/
test.yml
File metadata and controls
62 lines (52 loc) · 1.38 KB
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: Tests
on:
push:
branches:
- master
path-ignore:
- 'README.md'
pull_request:
branches:
- master
path-ignore:
- 'README.md'
release:
types: [published]
jobs:
build:
if: "! contains(toJSON(github.event.commits.*.message), '[skip-ci]')"
strategy:
matrix:
nim: ['1.0.x', '1.2.x', '1.4.x', 'stable', 'devel']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Get Date
id: get-date
run: echo "::set-output name=date::$(date "+%Y-%m-%d")"
shell: bash
- name: Cache choosenim
id: cache-choosenim
uses: actions/cache@v1
with:
path: ~/.choosenim
key: ${{ runner.os }}-choosenim-${{ steps.get-date.outputs.date }}
- name: Cache nimble
id: cache-nimble
uses: actions/cache@v1
with:
path: ~/.nimble
key: ${{ runner.os }}-nimble-${{ hashFiles('*.nimble') }}
if: runner.os != 'Windows'
- name: Set up Nim
uses: jiro4989/setup-nim-action@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
nim-version: ${{ matrix.nim }}
- name: Install dependencies
run: nimble install -d -y
- name: Run tests
run: nimble tests
- name: Try to build docs
run: nimble docs