git.iko.soy/typeable/http-api-data
on master help sign in
Merge pull request #63 from phadej/lower-bounds
4a24cc0Oleg Grenrus
.travis.yml+27−13
@@ -1,6 +1,6 @@
1# This Travis job script has been generated by a script via
1# This Travis job script has been generated by a script via
2#
2#
3−# make_travis_yml_2.hs '--branch' 'master' '-o' '.travis.yml' 'http-api-data.cabal'
3+# runghc make_travis_yml_2.hs '--config' '--output' '.travis.yml' 'http-api-data.cabal'
4#
4#
5# For more information, see https://github.com/hvr/multi-ghc-travis
5# For more information, see https://github.com/hvr/multi-ghc-travis
6#
6#
@@ -28,6 +28,8 @@ before_cache:
28 - rm -fv $HOME/.cabal/packages/hackage.haskell.org/01-index.tar
28 - rm -fv $HOME/.cabal/packages/hackage.haskell.org/01-index.tar
29 - rm -fv $HOME/.cabal/packages/hackage.haskell.org/01-index.tar.idx
29 - rm -fv $HOME/.cabal/packages/hackage.haskell.org/01-index.tar.idx
30
30
31+ - rm -fv $HOME/.cabal/packages/head.hackage
32+
31matrix:
33matrix:
32 include:
34 include:
33 - compiler: "ghc-7.8.4"
35 - compiler: "ghc-7.8.4"
@@ -47,7 +49,11 @@ before_install:
47 - HC=${CC}
49 - HC=${CC}
48 - HCPKG=${HC/ghc/ghc-pkg}
50 - HCPKG=${HC/ghc/ghc-pkg}
49 - unset CC
51 - unset CC
52+ - ROOTDIR=$(pwd)
53+ - mkdir -p $HOME/.local/bin
50− - PATH=/opt/ghc/bin:/opt/ghc-ppa-tools/bin:$PATH
54+ - "PATH=/opt/ghc/bin:/opt/ghc-ppa-tools/bin:$HOME/local/bin:$PATH"
55+ - HCNUMVER=$(( $(${HC} --numeric-version|sed -E 's/([0-9]+)\.([0-9]+)\.([0-9]+).*/\1 * 10000 + \2 * 100 + \3/') ))
56+ - echo $HCNUMVER
51
57
52install:
58install:
53 - cabal --version
59 - cabal --version
@@ -56,12 +62,16 @@ install:
56 - TEST=${TEST---enable-tests}
62 - TEST=${TEST---enable-tests}
57 - HADDOCK=${HADDOCK-true}
63 - HADDOCK=${HADDOCK-true}
58 - INSTALLED=${INSTALLED-true}
64 - INSTALLED=${INSTALLED-true}
65+ - GHCHEAD=${GHCHEAD-false}
59 - travis_retry cabal update -v
66 - travis_retry cabal update -v
60− - sed -i.bak 's/^jobs:/-- jobs:/' ${HOME}/.cabal/config
67+ - "sed -i.bak 's/^jobs:/-- jobs:/' ${HOME}/.cabal/config"
61− - rm -fv cabal.project.local
68+ - rm -fv cabal.project cabal.project.local
69+ - "if [ $HCNUMVER -ge 70800 ]; then sed -i.bak 's/-- ghc-options:.*/ghc-options: -j2/' ${HOME}/.cabal/config; fi"
70+ - grep -Ev -- '^\s*--' ${HOME}/.cabal/config | grep -Ev '^\s*$'
62− - "echo 'packages: .' > cabal.project"
71+ - "printf 'packages: \".\"\\n' > cabal.project"
72+ - cat cabal.project
63 - if [ -f "./configure.ac" ]; then
73 - if [ -f "./configure.ac" ]; then
64− (cd "."; autoreconf -i);
74+ (cd "." && autoreconf -i);
65 fi
75 fi
66 - rm -f cabal.project.freeze
76 - rm -f cabal.project.freeze
67 - cabal new-build -w ${HC} ${TEST} ${BENCH} --project-file="cabal.project" --dep -j2 all
77 - cabal new-build -w ${HC} ${TEST} ${BENCH} --project-file="cabal.project" --dep -j2 all
@@ -73,26 +83,30 @@ install:
73# any command which exits with a non-zero exit code causes the build to fail.
83# any command which exits with a non-zero exit code causes the build to fail.
74script:
84script:
75 # test that source-distributions can be generated
85 # test that source-distributions can be generated
76− - (cd "."; cabal sdist)
86+ - (cd "." && cabal sdist)
77 - mv "."/dist/http-api-data-*.tar.gz ${DISTDIR}/
87 - mv "."/dist/http-api-data-*.tar.gz ${DISTDIR}/
78− - cd ${DISTDIR}
88+ - cd ${DISTDIR} || false
79 - find . -maxdepth 1 -name '*.tar.gz' -exec tar -xvf '{}' \;
89 - find . -maxdepth 1 -name '*.tar.gz' -exec tar -xvf '{}' \;
80− - "printf 'packages: http-api-data-*/*.cabal\n' > cabal.project"
90+ - "printf 'packages: http-api-data-*/*.cabal\\n' > cabal.project"
91+ - cat cabal.project
81 # this builds all libraries and executables (without tests/benchmarks)
92 # this builds all libraries and executables (without tests/benchmarks)
82 - cabal new-build -w ${HC} --disable-tests --disable-benchmarks all
93 - cabal new-build -w ${HC} --disable-tests --disable-benchmarks all
83
94
84 # Build with installed constraints for packages in global-db
95 # Build with installed constraints for packages in global-db
85− - if $INSTALLED; then
86− echo cabal new-build -w ${HC} --disable-tests --disable-benchmarks $(${HCPKG} list --global --simple-output --names-only | sed 's/\([a-zA-Z0-9-]\{1,\}\) */--constraint="\1 installed" /g') all | sh;
96+ - if $INSTALLED; then echo cabal new-build -w ${HC} --disable-tests --disable-benchmarks $(${HCPKG} list --global --simple-output --names-only | sed 's/\([a-zA-Z0-9-]\{1,\}\) */--constraint="\1 installed" /g') all | sh; else echo "Not building with installed constraints"; fi
87− else echo "Not building with installed constraints"; fi
88
97
89 # build & run tests, build benchmarks
98 # build & run tests, build benchmarks
90 - cabal new-build -w ${HC} ${TEST} ${BENCH} all
99 - cabal new-build -w ${HC} ${TEST} ${BENCH} all
91 - if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${TEST} all; fi
100 - if [ "x$TEST" = "x--enable-tests" ]; then cabal new-test -w ${HC} ${TEST} all; fi
92
101
102+ # cabal check
103+ - (cd http-api-data-* && cabal check)
104+
93 # haddock
105 # haddock
94 - rm -rf ./dist-newstyle
106 - rm -rf ./dist-newstyle
95 - if $HADDOCK; then cabal new-haddock -w ${HC} --disable-tests --disable-benchmarks all; else echo "Skipping haddock generation";fi
107 - if $HADDOCK; then cabal new-haddock -w ${HC} --disable-tests --disable-benchmarks all; else echo "Skipping haddock generation";fi
96
108
109+ - if [ $HCNUMVER -eq 70804 ]; then cabal new-build -w ${HC} --disable-tests --disable-benchmarks --constraint='attoparsec ==0.13.0.1' --constraint='attoparsec-iso8601 ==1.0.0.0' --constraint='bytestring ==0.10.4.0' --constraint='containers ==0.5.5.1' --constraint='hashable ==1.1.2.4' --constraint='http-types ==0.8.6' --constraint='text ==1.1.1.3' --constraint='time ==1.4.2' --constraint='time-local-compat ==0.1.1.0' --constraint='unordered-containers ==0.2.5.0' --constraint='uri-bytestring ==0.1.7' --constraint='uuid-types ==1.0.2' all; else echo skipping...; fi
110+
97−# REGENDATA ["--branch","master","-o",".travis.yml","http-api-data.cabal"]
111+# REGENDATA ["--config","--output",".travis.yml","http-api-data.cabal"]
98# EOF
112# EOF
http-api-data.cabal+17−14
@@ -5,7 +5,10 @@ license-file: LICENSE
5author: Nickolay Kudasov <nickolay.kudasov@gmail.com>
5author: Nickolay Kudasov <nickolay.kudasov@gmail.com>
6maintainer: Nickolay Kudasov <nickolay.kudasov@gmail.com>
6maintainer: Nickolay Kudasov <nickolay.kudasov@gmail.com>
7synopsis: Converting to/from HTTP API data like URL pieces, headers and query parameters.
7synopsis: Converting to/from HTTP API data like URL pieces, headers and query parameters.
8+description:
9+ This package defines typeclasses used for converting Haskell data types to and from HTTP API data.
10+ .
8−description: Please see README.md
11+ Please see README.md
9homepage: http://github.com/fizruk/http-api-data
12homepage: http://github.com/fizruk/http-api-data
10category: Web
13category: Web
11stability: unstable
14stability: unstable
@@ -36,19 +39,19 @@ flag use-text-show
36library
39library
37 hs-source-dirs: src/
40 hs-source-dirs: src/
38 include-dirs: include/
41 include-dirs: include/
39− build-depends: base >= 4.7 && < 4.11
42+ build-depends: base >= 4.7 && < 4.11
40− , attoparsec >= 0.13.0.1 && < 0.14
43+ , attoparsec >= 0.13.0.1 && < 0.14
41− , attoparsec-iso8601 >= 1.0.0.0 && < 1.1
44+ , attoparsec-iso8601 >= 1.0.0.0 && < 1.1
42− , bytestring
45+ , bytestring >= 0.10.4.0 && < 0.11
43− , containers
46+ , containers >= 0.5.5.1 && < 0.6
44− , hashable
47+ , hashable >= 1.1.2.4 && < 1.3
45− , http-types
48+ , http-types >= 0.8.3 && < 0.12
46− , text >= 0.5
49+ , text >= 1.1.1.3 && < 1.3
47− , time
50+ , time >= 1.4.2 && < 1.9
48− , time-locale-compat >=0.1.1.0 && <0.2
51+ , time-locale-compat >= 0.1.1.0 && < 0.2
49− , unordered-containers
52+ , unordered-containers >= 0.2.5.0 && < 0.3
50− , uri-bytestring
53+ , uri-bytestring >= 0.1.7 && < 0.4
51− , uuid-types >= 1.0.2 && <1.1
54+ , uuid-types >= 1.0.2 && <1.1
52 if flag(use-text-show)
55 if flag(use-text-show)
53 cpp-options: -DUSE_TEXT_SHOW
56 cpp-options: -DUSE_TEXT_SHOW
54 build-depends: text-show >= 2
57 build-depends: text-show >= 2