Skip to content

Commit cabb41f

Browse files
committed
Migrate back to github
1 parent a2221fa commit cabb41f

File tree

5 files changed

+139
-530
lines changed

5 files changed

+139
-530
lines changed

.github/workflows/test.yaml

Lines changed: 139 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
name: Haskell CI
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
9+
jobs:
10+
build:
11+
12+
runs-on: ${{ matrix.os }}
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
os: [ubuntu-latest, macOS-latest, windows-latest]
17+
ghc: ['8.0.2', '8.2.2', '8.4.4', '8.6.5', '8.8.4', '8.10.7', '9.0.2', '9.2.5']
18+
cabal: ['3.6.2.0']
19+
include:
20+
- os: ubuntu-latest
21+
ghc: 'HEAD'
22+
cabal: 3.6.2.0
23+
- os: ubuntu-latest
24+
ghc: 'recommended'
25+
- os: ubuntu-latest
26+
ghc: 'latest'
27+
cabal: 3.6.2.0
28+
exclude:
29+
- os: macOS-latest
30+
ghc: '8.0.2'
31+
- os: macOS-latest
32+
ghc: '8.2.2'
33+
- os: macOS-latest
34+
ghc: '8.4.4'
35+
- os: macOS-latest
36+
ghc: '8.6.5'
37+
- os: macOS-latest
38+
ghc: '8.8.4'
39+
- os: macOS-latest
40+
ghc: '9.0.2'
41+
- os: windows-latest
42+
ghc: '8.0.2'
43+
- os: windows-latest
44+
ghc: '8.2.2'
45+
- os: windows-latest
46+
ghc: '8.4.4'
47+
- os: windows-latest
48+
ghc: '8.6.5'
49+
- os: windows-latest
50+
ghc: '8.8.4'
51+
- os: windows-latest
52+
ghc: '9.0.2'
53+
54+
steps:
55+
- uses: actions/checkout@v2
56+
57+
- name: Install dependencies (Ubuntu)
58+
if: runner.os == "Linux"
59+
run: |
60+
apt-get -y update
61+
apt-get -y install libtinfo5 libtinfo6 libncurses5 libncurses6
62+
63+
- name: Install ghc/cabal
64+
run: |
65+
set -eux
66+
if [ "${{ matrix.ghc }}" == 'HEAD' ] ; then
67+
ghcup install ghc -u 'https://gitlab.haskell.org/api/v4/projects/1/jobs/artifacts/master/raw/ghc-x86_64-linux-deb10-unreg-validate.tar.xz?job=x86_64-linux-deb10-unreg-validate' head
68+
ghcup set ghc head
69+
else
70+
ghcup install ghc ${{ matrix.ghc }}
71+
ghcup set ghc ${{ matrix.ghc }}
72+
fi
73+
ghcup install cabal ${{ matrix.cabal }}
74+
shell: bash
75+
76+
- name: Build
77+
run: |
78+
set -eux
79+
[ "${{ matrix.ghc }}" == 'HEAD' ] ||
80+
[ "${{ matrix.ghc }}" == 'recommended' ] ||
81+
[ "${{ matrix.ghc }}" == 'latest' ] ||
82+
[ "$(ghc --numeric-version)" = "${{ matrix.ghc }}" ]
83+
cabal update
84+
cabal build --enable-tests --enable-benchmarks
85+
cabal test
86+
cabal haddock
87+
cabal check
88+
cabal sdist
89+
shell: bash
90+
91+
- if: matrix.os == 'ubuntu-latest'
92+
name: make all
93+
run: |
94+
set -eux
95+
export "PATH=$HOME/.cabal/bin:$PATH"
96+
cabal install --overwrite-policy=always --install-method=copy cpphs
97+
make all
98+
git diff --exit-code
99+
100+
emulated:
101+
needs: build
102+
runs-on: ubuntu-latest
103+
strategy:
104+
fail-fast: true
105+
matrix:
106+
arch: ['s390x', 'ppc64le', 'armv7', 'aarch64']
107+
steps:
108+
- uses: actions/checkout@v2
109+
- uses: uraimo/[email protected]
110+
timeout-minutes: 60
111+
with:
112+
arch: ${{ matrix.arch }}
113+
distro: ubuntu20.04
114+
githubToken: ${{ github.token }}
115+
install: |
116+
apt-get update -y
117+
apt-get install -y ghc libghc-quickcheck2-dev cpphs git make
118+
run: |
119+
ghc --version
120+
ghc --make -o Main tests/filepath-tests/Test.hs -itests/ -itests/filepath-tests/ +RTS -s
121+
./Main +RTS -s
122+
123+
emulated-i386:
124+
runs-on: ubuntu-latest
125+
container:
126+
image: i386/ubuntu:bionic
127+
steps:
128+
- name: install
129+
run: |
130+
apt-get update -y
131+
apt-get install -y ghc libghc-quickcheck2-dev cpphs git make
132+
shell: bash
133+
- uses: actions/checkout@v1
134+
- name: test
135+
run: |
136+
ghc --version
137+
ghc --make -o Main tests/filepath-tests/Test.hs -itests/ -itests/filepath-tests/ +RTS -s
138+
./Main +RTS -s
139+
shell: bash

0 commit comments

Comments
 (0)