-
Notifications
You must be signed in to change notification settings - Fork 2
82 lines (68 loc) · 3.04 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
name: CI
# Controls when the action will run. Triggers the workflow on push for any branch, and
# pull requests to master
on:
push:
pull_request:
branches: [ master ]
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
test:
name: ${{ matrix.lisp }} on ${{ matrix.os }}
strategy:
matrix:
# current ccl-bin has a flaky zip file, so roswell can't install it.
# Specify a version that works for now.
lisp: [sbcl-bin, ccl-bin/1.12]
os: [ windows-latest, ubuntu-latest, macos-latest]
# run the job on every combination of "lisp" and "os" above
runs-on: ${{ matrix.os }}
# default to msys2 shell on windows, since roswell install-for-ci.sh tries to install using pacman
defaults:
run:
shell: ${{ fromJSON('[ "bash", "msys2 {0}" ]') [ matrix.os == 'windows-latest' ] }}
steps:
# use setup-msys2
- uses: msys2/setup-msys2@v2
if: matrix.os == 'windows-latest'
with:
path-type: inherit
# list any extra packages we want installed
# for example the following would be enough for us to build sbcl
# from git:
# install: 'git base-devel unzip mingw-w64-x86_64-gcc mingw64/mingw-w64-x86_64-zlib'
# tell git not to convert line endings
# change roswell install dir and add it to path
- name: windows specific settings
if: matrix.os == 'windows-latest'
run: |
git config --global core.autocrlf false
echo "ROSWELL_INSTALL_DIR=$HOME/ros" >> $GITHUB_ENV
echo "$HOME/ros/bin" >> $GITHUB_PATH
# Check out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
- name: cache .roswell
id: cache-dot-roswell
uses: actions/cache@v1
with:
path: ~/.roswell
key: ${{ runner.os }}-dot-roswell-${{ matrix.lisp }}-${{ hashFiles('**/*.asd') }}
restore-keys: |
${{ runner.os }}-dot-roswell-${{ matrix.lisp }}-
${{ runner.os }}-dot-roswell-
- name: install roswell
# always run install, since it does some global installs and setup that isn't cached
env:
LISP: ${{ matrix.lisp }}
run: curl -L https://raw.githubusercontent.com/roswell/roswell/master/scripts/install-for-ci.sh | sh -x
- name: run lisp
continue-on-error: true
run: |
ros -e '(format t "~a:~a on ~a~%...~%~%" (lisp-implementation-type) (lisp-implementation-version) (machine-type))'
ros -e '(format t " fixnum bits:~a~%" (integer-length most-positive-fixnum))'
ros -e "(ql:quickload 'trivial-features)" -e '(format t "features = ~s~%" *features*)'
- name: update ql dist if we have one cached
run: ros -e "(ql:update-all-dists :prompt nil)"
- name: load code and run tests
run: |
ros -e '(handler-bind (#+asdf3.2(asdf:bad-SYSTEM-NAME (function MUFFLE-WARNING))) (handler-case (ql:quickload :ci-example/test) (error (a) (format t "caught error ~s~%~a~%" a a) (uiop:quit 123))))' -e '(ci-example.test:run-tests-for-ci)'