on master help sign in
update CI config files with new packcheck version
commitcce586ad126936b832b644566711b79f4eb4541d authorHarendra Kumar <harendra.kumar@gmail.com> dateSun 16 Jun 2019, 19:04 (7 years ago) parentfae4b72
3 files changed+142−58
.circleci/config.yml+108−22 .travis.yml+27−34 appveyor.yml+7−2
.circleci/config.yml+108−22
@@ -1,7 +1,7 @@
11version: 2
22
33#-----------------------------------------------------------------------------
4−# packcheck-0.3.1
4+# packcheck-0.4.2
55# Packcheck global environment variables
66#-----------------------------------------------------------------------------
77
@@ -44,7 +44,7 @@ env: &env
4444 # ------------------------------------------------------------------------
4545 # Where to find the required tools
4646 # ------------------------------------------------------------------------
47− #PATH: /bin:/usr/bin
47+ PATH: /opt/ghc/bin:/sbin:/usr/sbin:/bin:/usr/bin
4848 #TOOLS_DIR: /opt
4949
5050 # ------------------------------------------------------------------------
@@ -54,12 +54,11 @@ env: &env
5454 # you can use it by specifying the PACKCHECK_REPO_URL option below in which
5555 # case it will be automatically copied from the packcheck repo to this path
5656 # during CI tests. In any case it is finally invoked from this path.
57− PACKCHECK_LOCAL_PATH: "./packcheck.sh"
58− # If you have not committed packcheck.sh in your repo at PACKCHECK_LOCAL_PATH
57+ PACKCHECK: "./packcheck.sh"
58+ # If you have not committed packcheck.sh in your repo at PACKCHECK
5959 # then it is automatically pulled from this URL.
6060 PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/harendra-kumar/packcheck"
61− PACKCHECK_GITHUB_COMMIT: "42d90d6b93bee7741e577d0e3615754165c648f8"
62− PACKCHECK_CMD: "$PACKCHECK_LOCAL_PATH $BUILD PATH=/opt/ghc/bin:$PATH"
61+ PACKCHECK_GITHUB_COMMIT: "d11a8a68fef00f4932bbedd6134950495ccd7420"
6362
6463 docker:
6564 - image: debian:stretch
@@ -70,16 +69,23 @@ env: &env
7069
7170preinstall: &preinstall
7271 run: |
73− echo "deb http://downloads.haskell.org/debian stretch main" >> /etc/apt/sources.list
7472 apt-get update
75− apt-get install -y curl
76− # required for apt-key
77− apt-get install -y gnupg
78− # required for cache save and restore
73+ # required for https/cache save and restore
7974 apt-get install -y ca-certificates
75+
76+ # For ghc and cabal-install packages from haskell.org
77+ # gnupg is required for apt-key to work
78+ apt-get install -y gnupg
8079 apt-key adv --keyserver keyserver.ubuntu.com --recv-keys BA3CBA3FFE22B574
80+ echo "deb http://downloads.haskell.org/debian stretch main" >> /etc/apt/sources.list
8181 apt-get update
8282
83+ # required for packcheck
84+ apt-get install -y curl
85+
86+ # required for outbound https for stack and for stack setup
87+ apt-get install -y netbase xz-utils make
88+
8389 # If a custom stack-yaml is specified, replace the default with that
8490 if test -e "$STACK_YAML"; then rm -f stack.yaml && ln -sv $STACK_YAML stack.yaml; else true; fi
8591 unset STACK_YAML
@@ -87,8 +93,8 @@ preinstall: &preinstall
8793 # Get packcheck if needed
8894 CURL=$(which curl)
8995 PACKCHECK_URL=${PACKCHECK_GITHUB_URL}/${PACKCHECK_GITHUB_COMMIT}/packcheck.sh
90− if test ! -e "$PACKCHECK_LOCAL_PATH"; then $CURL -sL -o "$PACKCHECK_LOCAL_PATH" $PACKCHECK_URL; fi;
91− chmod +x $PACKCHECK_LOCAL_PATH
96+ if test ! -e "$PACKCHECK"; then $CURL -sL -o "$PACKCHECK" $PACKCHECK_URL; fi;
97+ chmod +x $PACKCHECK
9298
9399restore: &restore
94100 # Needs to happen after installing ca-certificates
@@ -97,19 +103,92 @@ restore: &restore
97103
98104save: &save
99105 save_cache:
100− key: v1-{{ .Environment.CIRCLE_JOB }}-{{ .Branch }}
101− paths:
102− - ~/.cabal
103− - ~/.ghc
104− - ~/.local
105− - ~/.stack
106+ key: v1-{{ .Environment.CIRCLE_JOB }}-{{ .Branch }}
107+ paths:
108+ - ~/.cabal
109+ - ~/.ghc
110+ - ~/.local
111+ - ~/.stack
106112
107113#-----------------------------------------------------------------------------
108114# Build matrix
109115#-----------------------------------------------------------------------------
110116
111117jobs:
112− coveralls:
118+ cabal-ghc-8.6.5:
119+ <<: *env
120+ steps:
121+ - checkout
122+ - *preinstall
123+ - *restore
124+ - run: |
125+ apt-get install -y ghc-8.6.3
126+ apt-get install -y cabal-install-2.4
127+ bash -c "$PACKCHECK cabal-v2"
128+ - *save
129+ cabal-ghc-8.4.4:
130+ <<: *env
131+ steps:
132+ - checkout
133+ - *preinstall
134+ - *restore
135+ - run: |
136+ apt-get install -y ghc-8.4.4
137+ apt-get install -y cabal-install-2.4
138+ bash -c "$PACKCHECK cabal-v2"
139+ - *save
140+ cabal-ghc-8.2.2:
141+ <<: *env
142+ steps:
143+ - checkout
144+ - *preinstall
145+ - *restore
146+ - run: |
147+ apt-get install -y ghc-8.2.2
148+ apt-get install -y cabal-install-2.4
149+ bash -c "$PACKCHECK cabal-v2"
150+ - *save
151+ cabal-ghc-8.0.2:
152+ <<: *env
153+ steps:
154+ - checkout
155+ - *preinstall
156+ - *restore
157+ - run: |
158+ apt-get install -y ghc-8.0.2
159+ apt-get install -y cabal-install-2.4
160+ bash -c "$PACKCHECK cabal-v2"
161+ - *save
162+ cabal-ghc-7.10.3:
163+ <<: *env
164+ steps:
165+ - checkout
166+ - *preinstall
167+ - *restore
168+ - run: |
169+ apt-get install -y ghc-7.10.3
170+ apt-get install -y cabal-install-2.4
171+ bash -c "$PACKCHECK cabal-v2"
172+ - *save
173+ stack-ghc-8.4:
174+ <<: *env
175+ steps:
176+ - checkout
177+ - *preinstall
178+ - *restore
179+ - run: |
180+ bash -c "$PACKCHECK stack RESOLVER=lts-12"
181+ - *save
182+ stack-ghc-8.2:
183+ <<: *env
184+ steps:
185+ - checkout
186+ - *preinstall
187+ - *restore
188+ - run: |
189+ bash -c "$PACKCHECK stack RESOLVER=lts-11"
190+ - *save
191+ coveralls-ghc-8.2.2:
113192 <<: *env
114193 steps:
115194 - checkout
@@ -126,11 +205,18 @@ jobs:
126205 # required by hpc-coveralls
127206 apt-get install -y libcurl4-gnutls-dev
128207 apt-get install -y git
129− bash -c "$PACKCHECK_CMD"
208+ bash -c "$PACKCHECK cabal-v1"
130209 - *save
131210
132211workflows:
133212 version: 2
134213 build:
135214 jobs:
136− - coveralls
215+ #- cabal-ghc-8.6.5
216+ #- cabal-ghc-8.4.4
217+ #- cabal-ghc-8.2.2
218+ #- cabal-ghc-8.0.2
219+ #- cabal-ghc-7.10.3
220+ #- stack-ghc-8.4
221+ #- stack-ghc-8.2
222+ - coveralls-ghc-8.2.2
.travis.yml+27−34
@@ -1,4 +1,4 @@
1−# packcheck-0.4.0
1+# packcheck-0.4.2
22# You can use any of the options supported by packcheck as environment
33# variables here. See https://github.com/harendra-kumar/packcheck for all
44# options and their explanation.
@@ -59,7 +59,7 @@ env:
5959 # If you have not committed packcheck.sh in your repo at PACKCHECK_LOCAL_PATH
6060 # then it is automatically pulled from this URL.
6161 - PACKCHECK_GITHUB_URL="https://raw.githubusercontent.com/harendra-kumar/packcheck"
62− - PACKCHECK_GITHUB_COMMIT="42d90d6b93bee7741e577d0e3615754165c648f8"
62+ - PACKCHECK_GITHUB_COMMIT="d11a8a68fef00f4932bbedd6134950495ccd7420"
6363
6464notifications:
6565 email:
@@ -77,47 +77,40 @@ matrix:
7777 include:
7878
7979 # --------------------------------------------------------------------------
80− # (Linux) cabal builds (BUILD=cabal, BUILD=cabal-new). Common envvars are:
81− # CABAL_CONFIGURE_OPTIONS (cabal), CABAL_NEWBUILD_OPTIONS (cabal-new)
80+ # (Linux) cabal builds (BUILD=cabal-v1, BUILD=cabal-v2). Common envvars are:
81+ # CABAL_CONFIGURE_OPTIONS (cabal-v1), CABAL_BUILD_OPTIONS (cabal-v2)
8282 # --------------------------------------------------------------------------
8383
84− #- env: BUILD=cabal-new GHCVER=head
84+ #- env: BUILD=cabal-v2 GHCVER=head
8585 # addons: {apt: {packages: [cabal-install-head,ghc-head], sources: [hvr-ghc]}}
8686
87− - env: BUILD=cabal-new GHCVER=8.6.5 GHC_OPTIONS="" CABAL_NEWBUILD_OPTIONS="--flags streamk"
87+ - env: BUILD=cabal-v2 GHCVER=8.6.5 GHC_OPTIONS="" CABAL_BUILD_OPTIONS="--flags streamk"
8888 addons: {apt: {packages: [cabal-install-head,ghc-8.6.5], sources: [hvr-ghc]}}
8989
90− #- env: BUILD=cabal-new GHCVER=8.6.5 GHC_OPTIONS="" CABAL_NEWBUILD_OPTIONS="--flags examples-sdl"
91− # addons: {apt: {packages: [cabal-install-head,ghc-8.6.4,libsdl1.2-dev], sources: [hvr-ghc]}}
92−
93− - env: BUILD=cabal-new GHC_OPTIONS="" GHCVER=8.4.4
90+ - env: BUILD=cabal-v2 GHC_OPTIONS="" GHCVER=8.4.4
9491 addons: {apt: {packages: [cabal-install-head,ghc-8.4.4], sources: [hvr-ghc]}}
9592
96− #- env: BUILD=cabal-new GHCVER=8.2.2
97− # addons: {apt: {packages: [cabal-install-2.0,ghc-8.2.2], sources: [hvr-ghc]}}
93+ #- env: BUILD=cabal-v2 GHCVER=8.2.2
94+ # addons: {apt: {packages: [cabal-install-2.4,ghc-8.2.2], sources: [hvr-ghc]}}
9895
99− # Disable warnings because COMPLETE pragma is not available in this GHC
100− # version
101− - env: BUILD=cabal-new GHCVER=8.0.2 GHC_OPTIONS="" CABAL_NEWBUILD_OPTIONS="--flags examples-sdl"
96+ - env: BUILD=cabal-v2 GHCVER=8.0.2 GHC_OPTIONS="" CABAL_BUILD_OPTIONS="--flags examples-sdl"
10297 addons: {apt: {packages: [cabal-install-2.4,ghc-8.0.2,libsdl1.2-dev], sources: [hvr-ghc]}}
10398
104− # For 7.10.3 we disable -Werror because of some bogus SPECIALIZE pragma
105− # warnings.
106− - env: BUILD=cabal-new GHCVER=7.10.3 GHC_OPTIONS="" CABAL_NEWBUILD_OPTIONS="--flags examples-sdl"
99+ - env: BUILD=cabal-v2 GHCVER=7.10.3 GHC_OPTIONS="" CABAL_BUILD_OPTIONS="--flags examples-sdl"
107100 addons: {apt: {packages: [cabal-install-2.4,ghc-7.10.3,libsdl1.2-dev], sources: [hvr-ghc]}}
108101
109102 # You can specify build flags like this:
110− #- env: BUILD=cabal-new CABAL_NEWBUILD_OPTIONS="--flags=dev"
103+ #- env: BUILD=cabal-v2 CABAL_BUILD_OPTIONS="--flags=dev"
111104 # addons: {apt: {packages: [cabal-install-head,ghc-head], sources: [hvr-ghc]}}
112105
113106 # --------------------------------------------------------------------------
114107 # GHCJS cabal builds
115108 # --------------------------------------------------------------------------
116109
117− # Use CABAL_NEWBUILD_OPTIONS to pass any options to cabal e.g. project-file
110+ # Use CABAL_BUILD_OPTIONS to pass any options to cabal e.g. project-file
118111 # DISABLE_SDIST_BUILD is set because of a cabal issue. 'cabal info'
119112 # unnecessarily requires "ghc".
120− - env: BUILD=cabal-new ENABLE_GHCJS=y ENABLE_INSTALL= DISABLE_SDIST_BUILD=y
113+ - env: BUILD=cabal-v2 ENABLE_GHCJS=y ENABLE_INSTALL= DISABLE_SDIST_BUILD=y
121114 addons:
122115 apt:
123116 sources:
@@ -131,6 +124,10 @@ matrix:
131124 # (Linux) stack builds (BUILD=stack). Some common envvars for stack builds
132125 # are: STACK_YAML, STACK_OPTIONS, STACK_BUILD_OPTIONS
133126 # --------------------------------------------------------------------------
127+ #
128+ # NOTE: cabal-install is required for some of the packcheck options to work.
129+ # We just install it so that packcheck does not build it from source
130+ # otherwise.
134131
135132 #- env: BUILD=stack RESOLVER=nightly
136133 # addons: {apt: {packages: [cabal-install-1.24], sources: [hvr-ghc]}}
@@ -146,15 +143,11 @@ matrix:
146143 - env: BUILD=stack GHCVER=8.2.2 RESOLVER=lts-11 GHC_OPTIONS="" DISABLE_SDIST_BUILD=y DISABLE_DIST_CHECKS=y DISABLE_BENCH=y
147144 addons: {apt: {packages: [cabal-install-2.4], sources: [hvr-ghc]}}
148145
149− # Disable warnings because COMPLETE pragma is not available in this GHC
150− # version
151− #- env: BUILD=stack RESOLVER=lts-9 GHCVER=8.0.2 GHC_OPTIONS="" STACK_YAML=stack-8.0.yaml DISABLE_SDIST_BUILD=y DISABLE_DIST_CHECKS=y STACK_BUILD_OPTIONS="--flag streamly:examples-sdl"
152− # addons: {apt: {packages: [cabal-install-2.4,libsdl1.2-dev], sources: [hvr-ghc]}}
146+ #- env: BUILD=stack RESOLVER=lts-9 GHCVER=8.0
147+ # addons: {apt: {packages: [cabal-install-2.4], sources: [hvr-ghc]}}
153148
154− # For 7.10.3 we disable -Werror because of some bogus SPECIALIZE pragma
155− # warnings.
156− #- env: BUILD=stack RESOLVER=lts-6 GHCVER=7.10.3 GHC_OPTIONS="" STACK_YAML=stack-7.10.yaml DISABLE_SDIST_BUILD=y DISABLE_DIST_CHECKS=y STACK_BUILD_OPTIONS="--flag streamly:examples-sdl"
157− # addons: {apt: {packages: [cabal-install-2.4,libsdl1.2-dev], sources: [hvr-ghc]}}
149+ #- env: BUILD=stack RESOLVER=lts-6 GHCVER=7.10
150+ # addons: {apt: {packages: [cabal-install-2.4], sources: [hvr-ghc]}}
158151
159152 # You can keep a STACK_YAML file at any path location
160153 #- env: BUILD=stack STACK_YAML=.ci/stack-8.0.yaml
@@ -168,7 +161,7 @@ matrix:
168161
169162 # GHC 8.6 cabal build using stack!
170163 # On OSX autoreconf is not installed therefore disable sdist build
171− - env: BUILD=cabal-new RESOLVER=lts-13 GHCVER=8.6 GHC_OPTIONS="" DISABLE_SDIST_BUILD=y
164+ - env: BUILD=cabal-v2 RESOLVER=lts-13 GHCVER=8.6 GHC_OPTIONS="" DISABLE_SDIST_BUILD=y
172165 os: osx
173166
174167 # GHC 8.4/stack
@@ -185,22 +178,22 @@ matrix:
185178 # Build and send coverage report to coveralls.io using hpc-coveralls. Add
186179 # your project to coveralls.io first, for available options see hpc-coveralls
187180 # docs. CAVEATS:
188− # * Works only with BUILD=cabal
181+ # * Works only with BUILD=cabal-v1
189182 # * Does not work for multi-package repos
190183 # * hpc-coveralls does not build with Cabal-2.2/GHC-8.4.3. The workaround is
191184 # to have a prebuilt hpc-coveralls binary installed on the build machine
192185 # and then you can use any version of ghc.
193186 # --------------------------------------------------------------------------
194187
195− #- env: BUILD=cabal COVERALLS_OPTIONS="--coverage-mode=StrictlyFullLines --exclude-dir=test test"
196− # addons: {apt: {packages: [cabal-install-2.0,ghc-8.2.2], sources: [hvr-ghc]}}
188+ #- env: BUILD=cabal-v1 COVERALLS_OPTIONS="--coverage-mode=StrictlyFullLines --exclude-dir=test test"
189+ # addons: {apt: {packages: [cabal-install-2.4,ghc-8.2.2], sources: [hvr-ghc]}}
197190
198191 # --------------------------------------------------------------------------
199192 # Builds that are allowed to fail
200193 # --------------------------------------------------------------------------
201194
202195 allow_failures:
203− - env: BUILD=cabal-new GHCVER=head GHC_OPTIONS=""
196+ - env: BUILD=cabal-v2 GHCVER=head GHC_OPTIONS=""
204197 - env: BUILD=stack RESOLVER=nightly DISABLE_SDIST_BUILD=y DISABLE_DIST_CHECKS=y
205198 - env: BUILD=stack RESOLVER=lts-13 HLINT_COMMANDS="hlint lint ."
206199
appveyor.yml+7−2
@@ -1,3 +1,4 @@
1+# packcheck-0.4.2
12# You can use any of the options supported by packcheck as environment
23# variables here. See https://github.com/harendra-kumar/packcheck for all
34# options and their explanation.
@@ -19,8 +20,8 @@ environment:
1920 # DISABLE_TEST: "y"
2021 # DISABLE_BENCH: "y"
2122 # DISABLE_DOCS: "y"
22− DISABLE_DIST_CHECKS: "y"
2323 DISABLE_SDIST_BUILD: "y"
24+ DISABLE_DIST_CHECKS: "y"
2425 ENABLE_INSTALL: "y"
2526
2627 # ------------------------------------------------------------------------
@@ -58,7 +59,11 @@ environment:
5859 # If you have not committed packcheck.sh in your repo at PACKCHECK_LOCAL_PATH
5960 # then it is automatically pulled from this URL.
6061 PACKCHECK_GITHUB_URL: "https://raw.githubusercontent.com/harendra-kumar/packcheck"
61− PACKCHECK_GITHUB_COMMIT: "42d90d6b93bee7741e577d0e3615754165c648f8"
62+ PACKCHECK_GITHUB_COMMIT: "d11a8a68fef00f4932bbedd6134950495ccd7420"
63+
64+ # Override the temp directory to avoid sed escaping issues
65+ # See https://github.com/haskell/cabal/issues/5386
66+ TMP: "c:\\tmp"
6267
6368cache:
6469 - "%STACK_ROOT%"