-
Notifications
You must be signed in to change notification settings - Fork 3
58 lines (56 loc) · 1.32 KB
/
ci.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
name: CI
on:
pull_request:
branches:
- 'main'
push:
branches:
- 'main'
jobs:
check_format:
runs-on: ubuntu-latest
container:
image: crystallang/crystal:latest-alpine
steps:
- uses: actions/checkout@v2
- name: Check Format
run: crystal tool format --check
coding_standards:
runs-on: ubuntu-latest
container:
image: crystallang/crystal:latest-alpine
steps:
- uses: actions/checkout@v2
- name: Install Dependencies
run: shards install
- name: Ameba
run: ./bin/ameba
test:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- macos-latest
# - windows-latest
crystal:
- latest
- nightly
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
if: github.event_name != 'pull_request'
- uses: actions/checkout@v2
if: github.event_name == 'pull_request'
with:
fetch-depth: 0
- name: Install Crystal
uses: crystal-lang/install-crystal@v1
with:
crystal: ${{ matrix.crystal }}
- name: Install Dependencies
run: shards install
- name: Specs
run: crystal spec
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}