git.iko.soy/typeable/file-embed
on master help sign in
CI update
commitd5cf23df5291e365ad7cba1870b708eb1d21c03f authorMichael Snoyman <michael@snoyman.com> dateTue 24 Jul 2018, 08:26 (8 years ago) parent47ad3a5
4 files changed+64−12
.gitignore+1 .travis.yml+27−12 README.md+4 appveyor.yml+32
.gitignore+1
@@ -1,3 +1,4 @@
11dist
22*.swp
33.stack-work
4+/tarballs/
.travis.yml+27−12
@@ -20,6 +20,7 @@ cache:
2020 - $HOME/.ghc
2121 - $HOME/.cabal
2222 - $HOME/.stack
23+ - $TRAVIS_BUILD_DIR/.stack-work
2324
2425# The different configurations we want to test. We have BUILD=cabal which uses
2526# cabal-install, and BUILD=stack which uses Stack. More documentation on each
@@ -56,9 +57,12 @@ matrix:
5657 - env: BUILD=cabal GHCVER=8.0.2 CABALVER=1.24 HAPPYVER=1.19.5 ALEXVER=3.1.7
5758 compiler: ": #GHC 8.0.2"
5859 addons: {apt: {packages: [cabal-install-1.24,ghc-8.0.2,happy-1.19.5,alex-3.1.7], sources: [hvr-ghc]}}
59− - env: BUILD=cabal GHCVER=8.2.1 CABALVER=2.0
60− compiler: ": #GHC 8.2.1"
61− addons: {apt: {packages: [cabal-install-2.0,ghc-8.2.1], sources: [hvr-ghc]}}
60+ - env: BUILD=cabal GHCVER=8.2.2 CABALVER=2.0 HAPPYVER=1.19.5 ALEXVER=3.1.7
61+ compiler: ": #GHC 8.2.2"
62+ addons: {apt: {packages: [cabal-install-2.0,ghc-8.2.2,happy-1.19.5,alex-3.1.7], sources: [hvr-ghc]}}
63+ - env: BUILD=cabal GHCVER=8.4.3 CABALVER=2.2 HAPPYVER=1.19.5 ALEXVER=3.1.7
64+ compiler: ": #GHC 8.4.3"
65+ addons: {apt: {packages: [cabal-install-2.2,ghc-8.4.3,happy-1.19.5,alex-3.1.7], sources: [hvr-ghc]}}
6266
6367 # Build with the newest GHC and cabal-install. This is an accepted failure,
6468 # see below.
@@ -92,6 +96,10 @@ matrix:
9296 compiler: ": #stack 8.0.2"
9397 addons: {apt: {packages: [libgmp-dev]}}
9498
99+ - env: BUILD=stack ARGS="--resolver lts-11"
100+ compiler: ": #stack 8.2.2"
101+ addons: {apt: {packages: [libgmp-dev]}}
102+
95103 # Nightly builds are allowed to fail
96104 - env: BUILD=stack ARGS="--resolver nightly"
97105 compiler: ": #stack nightly"
@@ -123,6 +131,10 @@ matrix:
123131 compiler: ": #stack 8.0.2 osx"
124132 os: osx
125133
134+ - env: BUILD=stack ARGS="--resolver lts-11"
135+ compiler: ": #stack 8.2.2 osx"
136+ os: osx
137+
126138 - env: BUILD=stack ARGS="--resolver nightly"
127139 compiler: ": #stack nightly osx"
128140 os: osx
@@ -145,9 +157,9 @@ before_install:
145157- |
146158 if [ `uname` = "Darwin" ]
147159 then
148− travis_retry curl --insecure -L https://www.stackage.org/stack/osx-x86_64 | tar xz --strip-components=1 --include '*/stack' -C ~/.local/bin
160+ travis_retry curl --insecure -L https://get.haskellstack.org/stable/osx-x86_64.tar.gz | tar xz --strip-components=1 --include '*/stack' -C ~/.local/bin
149161 else
150− travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
162+ travis_retry curl -L https://get.haskellstack.org/stable/linux-x86_64.tar.gz | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'
151163 fi
152164
153165 # Use the more reliable S3 mirror of Hackage
@@ -155,10 +167,6 @@ before_install:
155167 echo 'remote-repo: hackage.haskell.org:http://hackage.fpcomplete.com/' > $HOME/.cabal/config
156168 echo 'remote-repo-cache: $HOME/.cabal/packages' >> $HOME/.cabal/config
157169
158− if [ "$CABALVER" != "1.16" ]
159− then
160− echo 'jobs: $ncpus' >> $HOME/.cabal/config
161− fi
162170
163171install:
164172- echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]"
@@ -167,13 +175,16 @@ install:
167175 set -ex
168176 case "$BUILD" in
169177 stack)
178+ # Build the dependencies
170179 stack --no-terminal --install-ghc $ARGS test --bench --only-dependencies
171180 ;;
172181 cabal)
173182 cabal --version
174183 travis_retry cabal update
175184
176− # Get the list of packages from the stack.yaml file
185+ # Get the list of packages from the stack.yaml file. Note that
186+ # this will also implicitly run hpack as necessary to generate
187+ # the .cabal files needed by cabal-install.
177188 PACKAGES=$(stack --install-ghc query locals | grep '^ *path' | sed 's@^ *path:@@')
178189
179190 cabal install --only-dependencies --enable-tests --enable-benchmarks --force-reinstalls --ghc-options=-O0 --reorder-goals --max-backjumps=-1 $CABALARGS $PACKAGES
@@ -202,9 +213,13 @@ script:
202213 cd dist
203214 tar zxfv "$SRC_TGZ"
204215 cd "$PKGVER"
205− cabal configure --enable-tests
216+ cabal configure --enable-tests --ghc-options -O0
206217 cabal build
207− cabal test
218+ if [ "$CABALVER" = "1.16" ] || [ "$CABALVER" = "1.18" ]; then
219+ cabal test
220+ else
221+ cabal test --show-details=streaming --log=/dev/stdout
222+ fi
208223 cd $ORIGDIR
209224 done
210225 ;;
README.md+4
@@ -1,4 +1,8 @@
11## file-embed
22
3+[![Build Status](https://travis-ci.org/snoyberg/file-embed.svg?branch=master)](https://travis-ci.org/snoyberg/file-embed)
4+[![Build status](https://ci.appveyor.com/api/projects/status/vlgo8uudpt374uoy/branch/master?svg=true)](https://ci.appveyor.com/project/snoyberg/file-embed/branch/master)
5+
6+
37Use Template Haskell to read a file or all the files in a directory, and turn
48them into (path, bytestring) pairs embedded in your haskell code.
appveyor.ymlnew file+32
@@ -0,0 +1,32 @@
1+build: off
2+
3+before_test:
4+# http://help.appveyor.com/discussions/problems/6312-curl-command-not-found
5+- set PATH=C:\Program Files\Git\mingw64\bin;%PATH%
6+
7+- curl -sS -ostack.zip -L --insecure https://get.haskellstack.org/stable/windows-x86_64.zip
8+- 7z x stack.zip stack.exe
9+
10+clone_folder: "c:\\stack"
11+environment:
12+ global:
13+ STACK_ROOT: "c:\\sr"
14+
15+ matrix:
16+ - ARGS: ""
17+ #- ARGS: "--resolver lts-2"
18+ #- ARGS: "--resolver lts-3"
19+ - ARGS: "--resolver lts-6"
20+ - ARGS: "--resolver lts-7"
21+ - ARGS: "--resolver lts-9"
22+ - ARGS: "--resolver lts-11"
23+ #- ARGS: "--resolver nightly"
24+
25+test_script:
26+
27+# Install toolchain, but do it silently due to lots of output
28+- stack %ARGS% setup > nul
29+
30+# The ugly echo "" hack is to avoid complaints about 0 being an invalid file
31+# descriptor
32+- echo "" | stack %ARGS% --no-terminal test --pedantic