Hello community, here is the log from the commit of package ghc-pipes-cacophony for openSUSE:Factory checked in at 2017-08-31 20:48:40 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ghc-pipes-cacophony (Old) and /work/SRC/openSUSE:Factory/.ghc-pipes-cacophony.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "ghc-pipes-cacophony" Thu Aug 31 20:48:40 2017 rev:3 rq:513450 version:0.5.0 Changes: -------- --- /work/SRC/openSUSE:Factory/ghc-pipes-cacophony/ghc-pipes-cacophony.changes 2017-04-18 13:48:34.569944394 +0200 +++ /work/SRC/openSUSE:Factory/.ghc-pipes-cacophony.new/ghc-pipes-cacophony.changes 2017-08-31 20:48:41.980836473 +0200 @@ -1,0 +2,10 @@ +Sun Jul 30 03:01:24 UTC 2017 - psimons@suse.com + +- Update to version 0.5.0 revision 1. + +------------------------------------------------------------------- +Thu Jul 27 14:07:28 UTC 2017 - psimons@suse.com + +- Update to version 0.5.0. + +------------------------------------------------------------------- Old: ---- pipes-cacophony-0.4.1.tar.gz New: ---- pipes-cacophony-0.5.0.tar.gz pipes-cacophony.cabal ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ghc-pipes-cacophony.spec ++++++ --- /var/tmp/diff_new_pack.OwpGHg/_old 2017-08-31 20:48:43.120676476 +0200 +++ /var/tmp/diff_new_pack.OwpGHg/_new 2017-08-31 20:48:43.128675353 +0200 @@ -19,17 +19,17 @@ %global pkg_name pipes-cacophony %bcond_with tests Name: ghc-%{pkg_name} -Version: 0.4.1 +Version: 0.5.0 Release: 0 Summary: Pipes for Noise-secured network connections License: SUSE-Public-Domain Group: Development/Languages/Other Url: https://hackage.haskell.org/package/%{pkg_name} Source0: https://hackage.haskell.org/package/%{pkg_name}-%{version}/%{pkg_name}-%{version}.tar.gz +Source1: https://hackage.haskell.org/package/%{pkg_name}-%{version}/revision/1.cabal#/%{pkg_name}.cabal BuildRequires: ghc-Cabal-devel BuildRequires: ghc-bytestring-devel BuildRequires: ghc-cacophony-devel -BuildRequires: ghc-memory-devel BuildRequires: ghc-pipes-devel BuildRequires: ghc-rpm-macros BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -55,6 +55,7 @@ %prep %setup -q -n %{pkg_name}-%{version} +cp -p %{SOURCE1} %{pkg_name}.cabal %build %ghc_lib_build ++++++ pipes-cacophony-0.4.1.tar.gz -> pipes-cacophony-0.5.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/.travis.yml new/pipes-cacophony-0.5.0/.travis.yml --- old/pipes-cacophony-0.4.1/.travis.yml 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/.travis.yml 2017-06-26 18:13:04.000000000 +0200 @@ -1,81 +1,36 @@ -# This file has been generated -- see https://github.com/hvr/multi-ghc-travis language: c -sudo: false +dist: trusty cache: directories: - - $HOME/.cabsnap - - $HOME/.cabal/packages + - $HOME/.stack -before_cache: - - rm -fv $HOME/.cabal/packages/hackage.haskell.org/build-reports.log - - rm -fv $HOME/.cabal/packages/hackage.haskell.org/00-index.tar +addons: + apt: + packages: + - libgmp-dev matrix: include: - - env: CABALVER=1.22 GHCVER=7.10.3 - compiler: ": #GHC 7.10.3" - addons: {apt: {packages: [cabal-install-1.22,ghc-7.10.3,alex-3.1.7,happy-1.19.5], sources: [hvr-ghc]}} - - env: CABALVER=1.24 GHCVER=8.0.2 - compiler: ": #GHC 8.0.2" - addons: {apt: {packages: [cabal-install-1.24,ghc-8.0.2,alex-3.1.7,happy-1.19.5], sources: [hvr-ghc]}} - - env: CABALVER=head GHCVER=head - compiler: ": #GHC head" - addons: {apt: {packages: [cabal-install-head,ghc-head,alex-3.1.7,happy-1.19.5], sources: [hvr-ghc]}} + - env: ARGS="--resolver lts-8" + compiler: ": #stack 8.0.2" + + - env: ARGS="--resolver nightly" + compiler: ": #stack nightly" allow_failures: - - env: CABALVER=head GHCVER=head + - env: ARGS="--resolver nightly" + compiler: ": #stack nightly" before_install: - unset CC - - export HAPPYVER=1.19.5 - - export ALEXVER=3.1.7 - - export PATH=~/.cabal/bin:/opt/ghc/$GHCVER/bin:/opt/cabal/$CABALVER/bin:/opt/happy/$HAPPYVER/bin:/opt/alex/$ALEXVER/bin:$PATH + - mkdir -p ~/.local/bin + - export PATH=$HOME/.local/bin:$PATH + - travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack' install: - - cabal --version - - echo "$(ghc --version) [$(ghc --print-project-git-commit-id 2> /dev/null || echo '?')]" - - if [ -f $HOME/.cabal/packages/hackage.haskell.org/00-index.tar.gz ]; - then - zcat $HOME/.cabal/packages/hackage.haskell.org/00-index.tar.gz > - $HOME/.cabal/packages/hackage.haskell.org/00-index.tar; - fi - - travis_retry cabal update - - "sed -i 's/^jobs:.*$/jobs: 2/' $HOME/.cabal/config" - - cabal install --only-dependencies --enable-tests -fbuild-examples --dry -v pipes-cacophony.cabal > installplan.txt - - sed -i -e '1,/^Resolving /d' installplan.txt; cat installplan.txt - - # check whether current requested install-plan matches cached package-db snapshot - - if diff -u installplan.txt $HOME/.cabsnap/installplan.txt; - then - echo "cabal build-cache HIT"; - rm -rfv .ghc; - cp -a $HOME/.cabsnap/ghc $HOME/.ghc; - cp -a $HOME/.cabsnap/lib $HOME/.cabsnap/share $HOME/.cabsnap/bin $HOME/.cabal/; - else - echo "cabal build-cache MISS"; - rm -rf $HOME/.cabsnap; - mkdir -p $HOME/.ghc $HOME/.cabal/lib $HOME/.cabal/share $HOME/.cabal/bin; - cabal install --only-dependencies --enable-tests -fbuild-examples pipes-cacophony.cabal; - fi - - # snapshot package-db on cache miss - - if [ ! -d $HOME/.cabsnap ]; - then - echo "snapshotting package-db to build-cache"; - mkdir $HOME/.cabsnap; - cp -a $HOME/.ghc $HOME/.cabsnap/ghc; - cp -a $HOME/.cabal/lib $HOME/.cabal/share $HOME/.cabal/bin installplan.txt $HOME/.cabsnap/; - fi + - stack $ARGS setup script: - - cabal configure --enable-tests -fbuild-examples -v2 # -v2 provides useful information for debugging - - cabal build # this builds all libraries and executables (including tests) - - cabal test - - cabal sdist # tests that a source-distribution can be generated - - # Check that the resulting source distribution can be built & installed. - # If there are no other `.tar.gz` files in `dist`, this can be even simpler: - # `cabal install --force-reinstalls dist/*-*.tar.gz` - - SRC_TGZ=$(cabal info . | awk '{print $2;exit}').tar.gz && - (cd dist && cabal install --enable-tests --run-tests -fbuild-examples --force-reinstalls "$SRC_TGZ") + - stack $ARGS --no-terminal test --flag "pipes-cacophony:build-examples" --haddock --no-haddock-deps + - stack sdist diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/changelog.md new/pipes-cacophony-0.5.0/changelog.md --- old/pipes-cacophony-0.4.1/changelog.md 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/changelog.md 2017-06-26 18:13:04.000000000 +0200 @@ -1,3 +1,7 @@ +# 0.5.0 + +* Brought up to date with cacophony API changes + # 0.4.1 * Brought up to date with cacophony API changes diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/examples/loopback/Main.hs new/pipes-cacophony-0.5.0/examples/loopback/Main.hs --- old/pipes-cacophony-0.4.1/examples/loopback/Main.hs 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/examples/loopback/Main.hs 2017-06-26 18:13:04.000000000 +0200 @@ -1,10 +1,8 @@ module Main where -import Control.Exception (SomeException) -import Control.Lens import Control.Monad (forever) -import Data.ByteArray (ScrubbedBytes, convert) import Data.ByteString.Char8 (unpack, pack) +import Data.Maybe (fromMaybe) import Pipes import qualified Pipes.Prelude as P @@ -17,28 +15,49 @@ import Pipes.Noise -strToSB :: Pipe String ScrubbedBytes IO (Either SomeException ()) +strToSB :: (Cipher c, DH d, Hash h) + => Pipe String ScrubbedBytes IO (NoiseResult c d h) strToSB = forever $ await >>= yield . convert . pack -sbToStr :: Pipe ScrubbedBytes String IO (Either SomeException ()) +sbToStr :: (Cipher c, DH d, Hash h) + => Pipe ScrubbedBytes String IO (NoiseResult c d h) sbToStr = forever $ await >>= yield . unpack . convert +performHandshake :: (Cipher c, DH d, Hash h) + => NoiseState c d h + -> NoiseState c d h + -> (NoiseState c d h, NoiseState c d h) +performHandshake ins rns = (ins'', rns'') + where + (NoiseResultMessage ct ins') = writeMessage mempty ins + (NoiseResultMessage _ rns') = readMessage ct rns + (NoiseResultMessage ct' rns'') = writeMessage mempty rns' + (NoiseResultMessage _ ins'') = readMessage ct' ins' + main :: IO () main = do iek <- dhGenKey :: IO (KeyPair Curve25519) rek <- dhGenKey :: IO (KeyPair Curve25519) - let idho = defaultHandshakeOpts noiseNN InitiatorRole - rdho = defaultHandshakeOpts noiseNN ResponderRole - iho = idho & hoLocalEphemeral .~ Just iek - rho = rdho & hoLocalEphemeral .~ Just rek - ins = noiseState iho :: NoiseState ChaChaPoly1305 Curve25519 SHA256 - rns = noiseState rho :: NoiseState ChaChaPoly1305 Curve25519 SHA256 - - (iip, iop) <- mkNoisePipes ins - (rip, rop) <- mkNoisePipes rns - - result <- runEffect $ (Right () <$ P.stdinLn) >-> strToSB >-> iop >-> rip >-> rop >-> iip >-> sbToStr >-> (Right () <$ P.stdoutLn) + let idho = defaultHandshakeOpts InitiatorRole "cacophony" + rdho = defaultHandshakeOpts ResponderRole "cacophony" + iho = setLocalEphemeral (Just iek) idho + rho = setLocalEphemeral (Just rek) rdho + ins = noiseState iho noiseNN :: NoiseState ChaChaPoly1305 Curve25519 SHA256 + rns = noiseState rho noiseNN :: NoiseState ChaChaPoly1305 Curve25519 SHA256 + + (ins', rns') = performHandshake ins rns + (iip, iop) = fromMaybe (error "unable to make Noise pipe") $ mkNoisePipes ins' + (rip, rop) = fromMaybe (error "unable to make Noise pipe") $ mkNoisePipes rns' + + result <- runEffect $ (undefined <$ P.stdinLn) + >-> strToSB + >-> iop + >-> rip + >-> rop + >-> iip + >-> sbToStr + >-> (undefined <$ P.stdoutLn) case result of - Left e -> print e - Right _ -> return () + NoiseResultException ex -> print ex + _ -> return () diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/package.yaml new/pipes-cacophony-0.5.0/package.yaml --- old/pipes-cacophony-0.4.1/package.yaml 1970-01-01 01:00:00.000000000 +0100 +++ new/pipes-cacophony-0.5.0/package.yaml 2017-06-26 18:20:38.000000000 +0200 @@ -0,0 +1,79 @@ +name: pipes-cacophony +synopsis: Pipes for Noise-secured network connections. +version: 0.5.0 +license: PublicDomain +license-file: LICENSE +maintainer: John Galt <jgalt@centromere.net> +category: Cryptography +github: centromere/pipes-cacophony +ghc-options: -Wall +description: | + A set of pipes to secure network connections with the + <https://github.com/trevp/noise/blob/master/noise.md Noise> protocol. +extra-source-files: + - .travis.yml + - README.md + - changelog.md + - LICENSE + - stack.yaml + - package.yaml + - tests/.hlint + +flags: + build-examples: + description: Build examples + default: False + manual: True + +library: + source-dirs: src + dependencies: + - base >= 4.9 && < 4.10 + - bytestring + - cacophony >= 0.10 + - pipes + + exposed-modules: + - Pipes.Noise + + default-extensions: + - OverloadedStrings + +tests: + hlint: + main: hlint.hs + source-dirs: tests/hlint + dependencies: + - base >= 4.9 && < 4.10 + - hlint + + ghc-options: + - -O2 + - -rtsopts + - -threaded + - -with-rtsopts=-N + +executables: + loopback: + source-dirs: examples/loopback + main: Main.hs + when: + - condition: 'flag(build-examples)' + then: + dependencies: + - base >= 4.9 && < 4.10 + - bytestring + - cacophony >= 0.10 + - pipes + - pipes-cacophony + else: + buildable: False + + ghc-options: + - -O2 + - -rtsopts + - -threaded + - -with-rtsopts=-N + + default-extensions: + - OverloadedStrings diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/pipes-cacophony.cabal new/pipes-cacophony-0.5.0/pipes-cacophony.cabal --- old/pipes-cacophony-0.4.1/pipes-cacophony.cabal 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/pipes-cacophony.cabal 2017-06-26 18:23:31.000000000 +0200 @@ -1,106 +1,79 @@ -name: pipes-cacophony -version: 0.4.1 -synopsis: Pipes for Noise-secured network connections. -license: PublicDomain -license-file: LICENSE -author: John Galt -maintainer: jgalt@centromere.net -homepage: https://github.com/centromere/pipes-cacophony -bug-reports: https://github.com/centromere/pipes-cacophony/issues -category: Pipes, Cryptography -build-type: Simple -cabal-version: >=1.10 -tested-with: GHC == 7.10.3, GHC == 8.0.2 -description: - A set of pipes to secure network connections with the - <https://github.com/trevp/noise/blob/master/noise.md Noise> protocol. +-- This file has been generated from package.yaml by hpack version 0.17.0. +-- +-- see: https://github.com/sol/hpack + +name: pipes-cacophony +version: 0.5.0 +synopsis: Pipes for Noise-secured network connections. +description: A set of pipes to secure network connections with the + <https://github.com/trevp/noise/blob/master/noise.md Noise> protocol. +category: Cryptography +homepage: https://github.com/centromere/pipes-cacophony#readme +bug-reports: https://github.com/centromere/pipes-cacophony/issues +maintainer: John Galt <jgalt@centromere.net> +license: PublicDomain +license-file: LICENSE +build-type: Simple +cabal-version: >= 1.10 extra-source-files: - .travis.yml - README.md - changelog.md - LICENSE - tests/.hlint + .travis.yml + changelog.md + LICENSE + package.yaml + README.md + stack.yaml + tests/.hlint source-repository head type: git - location: https://github.com/centromere/pipes-cacophony.git - --------------------------------------------------------------------------------- --- FLAGS - -flag hlint - description: Build hlint test + location: https://github.com/centromere/pipes-cacophony flag build-examples - description: Build example executables - default: False + description: Build examples manual: True - -flag llvm default: False - manual: True - --------------------------------------------------------------------------------- --- LIBRARY library + hs-source-dirs: + src + default-extensions: OverloadedStrings + ghc-options: -Wall build-depends: - base >=4.8 && <5, - bytestring, - cacophony >=0.9, - memory, - pipes - hs-source-dirs: src - default-language: Haskell2010 + base >= 4.9 && < 4.10 + , bytestring + , cacophony >= 0.10 + , pipes exposed-modules: - Pipes.Noise - ghc-options: -Wall -fwarn-tabs - - if flag(llvm) - ghc-options: -fllvm - --------------------------------------------------------------------------------- --- EXAMPLES - -executable loopback + Pipes.Noise + other-modules: + Paths_pipes_cacophony default-language: Haskell2010 - hs-source-dirs: examples/loopback - main-is: Main.hs +executable loopback + main-is: Main.hs + hs-source-dirs: + examples/loopback + default-extensions: OverloadedStrings + ghc-options: -Wall -O2 -rtsopts -threaded -with-rtsopts=-N if flag(build-examples) build-depends: - base >=4.8 && <5, - bytestring, - cacophony >=0.9, - lens, - memory, - pipes, - pipes-cacophony + base >= 4.9 && < 4.10 + , bytestring + , cacophony >= 0.10 + , pipes + , pipes-cacophony else buildable: False - - ghc-options: -threaded -O2 -rtsopts -with-rtsopts=-N -Wall -fwarn-tabs - - if flag(llvm) - ghc-options: -fllvm - --------------------------------------------------------------------------------- --- TESTS + default-language: Haskell2010 test-suite hlint - type: exitcode-stdio-1.0 - main-is: hlint.hs - ghc-options: -Wall -fwarn-tabs - hs-source-dirs: tests + type: exitcode-stdio-1.0 + main-is: hlint.hs + hs-source-dirs: + tests/hlint + ghc-options: -Wall -O2 -rtsopts -threaded -with-rtsopts=-N + build-depends: + base >= 4.9 && < 4.10 + , hlint default-language: Haskell2010 - - if !flag(hlint) - buildable: False - else - build-depends: - base >=4.8 && <5, - hlint - - if flag(llvm) - ghc-options: -fllvm diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/src/Pipes/Noise.hs new/pipes-cacophony-0.5.0/src/Pipes/Noise.hs --- old/pipes-cacophony-0.4.1/src/Pipes/Noise.hs 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/src/Pipes/Noise.hs 2017-06-26 18:17:46.000000000 +0200 @@ -1,4 +1,3 @@ -{-# LANGUAGE OverloadedStrings #-} ---------------------------------------------------------------- -- | -- Module : Pipes.Noise @@ -14,16 +13,13 @@ , mkNoisePipes ) where -import Control.Concurrent.MVar (MVar, newMVar, putMVar, takeMVar) -import Control.Exception (SomeException) -import Data.ByteArray (ScrubbedBytes) -import Data.ByteString (ByteString) -import Pipes (Pipe, MonadIO, await, yield, liftIO) - -import Crypto.Noise.Cipher (Cipher) -import Crypto.Noise.DH (DH) -import Crypto.Noise.Hash (Hash) +import Data.ByteString (ByteString) +import Pipes (Pipe, await, yield) + import Crypto.Noise +import Crypto.Noise.Cipher (Cipher) +import Crypto.Noise.DH (DH) +import Crypto.Noise.Hash (Hash) -- | Pipe used for inbound Noise messages. type InboundNoisePipe = Pipe ByteString ScrubbedBytes @@ -32,39 +28,40 @@ type OutboundNoisePipe = Pipe ScrubbedBytes ByteString -- | Creates a pair of Pipes, the first used for inbound messages and the --- second used for outbound messages. -mkNoisePipes :: (MonadIO m, Cipher c, DH d, Hash h) +-- second used for outbound messages. Note: The handshake for the given +-- 'NoiseState' must be complete. If it is not, this function will return +-- 'Nothing'. +mkNoisePipes :: (Monad m, Cipher c, DH d, Hash h) => NoiseState c d h - -> IO (InboundNoisePipe m (Either SomeException ()), - OutboundNoisePipe m (Either SomeException ())) -mkNoisePipes ns = do - nsmv <- liftIO . newMVar $ ns - return (inboundPipe nsmv, outboundPipe nsmv) - -inboundPipe :: (MonadIO m, Cipher c, DH d, Hash h) - => MVar (NoiseState c d h) - -> InboundNoisePipe m (Either SomeException ()) -inboundPipe nsmv = do + -> Maybe (InboundNoisePipe m (NoiseResult c d h), + OutboundNoisePipe m (NoiseResult c d h)) +mkNoisePipes ns | handshakeComplete ns = return (inboundPipe ns, outboundPipe ns) + | otherwise = Nothing + +inboundPipe :: (Monad m, Cipher c, DH d, Hash h) + => NoiseState c d h + -> InboundNoisePipe m (NoiseResult c d h) +inboundPipe ns = do msg <- await - ns <- liftIO . takeMVar $ nsmv - case readMessage ns msg of - Left e -> return . Left $ e - Right (pt, ns') -> do - liftIO . putMVar nsmv $ ns' + let result = readMessage (convert msg) ns + case result of + NoiseResultMessage pt ns' -> do yield pt - inboundPipe nsmv + inboundPipe ns' + NoiseResultNeedPSK _ -> return result + NoiseResultException _ -> return result -outboundPipe :: (MonadIO m, Cipher c, DH d, Hash h) - => MVar (NoiseState c d h) - -> OutboundNoisePipe m (Either SomeException ()) -outboundPipe nsmv = do +outboundPipe :: (Monad m, Cipher c, DH d, Hash h) + => NoiseState c d h + -> OutboundNoisePipe m (NoiseResult c d h) +outboundPipe ns = do msg <- await - ns <- liftIO . takeMVar $ nsmv - case writeMessage ns msg of - Left e -> return . Left $ e - Right (ct, ns') -> do - liftIO . putMVar nsmv $ ns' - yield ct - outboundPipe nsmv + let result = writeMessage msg ns + case result of + NoiseResultMessage ct ns' -> do + yield . convert $ ct + outboundPipe ns' + NoiseResultNeedPSK _ -> return result + NoiseResultException _ -> return result diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/stack.yaml new/pipes-cacophony-0.5.0/stack.yaml --- old/pipes-cacophony-0.4.1/stack.yaml 1970-01-01 01:00:00.000000000 +0100 +++ new/pipes-cacophony-0.5.0/stack.yaml 2017-06-26 18:24:27.000000000 +0200 @@ -0,0 +1,6 @@ +resolver: lts-8.20 +packages: + - '.' +extra-deps: [] +flags: {} +extra-package-dbs: [] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/tests/hlint/hlint.hs new/pipes-cacophony-0.5.0/tests/hlint/hlint.hs --- old/pipes-cacophony-0.4.1/tests/hlint/hlint.hs 1970-01-01 01:00:00.000000000 +0100 +++ new/pipes-cacophony-0.5.0/tests/hlint/hlint.hs 2017-06-26 18:13:04.000000000 +0200 @@ -0,0 +1,16 @@ +module Main where + +import Control.Monad +import Language.Haskell.HLint +import System.Environment +import System.Exit + +main :: IO () +main = do + args <- getArgs + hints <- hlint $ [ "src" + , "tests" + , "--hint=tests/.hlint" + , "--cpp-define=HLINT" + ] `mappend` args + unless (null hints) exitFailure diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pipes-cacophony-0.4.1/tests/hlint.hs new/pipes-cacophony-0.5.0/tests/hlint.hs --- old/pipes-cacophony-0.4.1/tests/hlint.hs 2016-12-26 17:17:05.000000000 +0100 +++ new/pipes-cacophony-0.5.0/tests/hlint.hs 1970-01-01 01:00:00.000000000 +0100 @@ -1,16 +0,0 @@ -module Main where - -import Control.Monad -import Language.Haskell.HLint -import System.Environment -import System.Exit - -main :: IO () -main = do - args <- getArgs - hints <- hlint $ [ "src" - , "tests" - , "--hint=tests/.hlint" - , "--cpp-define=HLINT" - ] `mappend` args - unless (null hints) exitFailure ++++++ pipes-cacophony.cabal ++++++ -- This file has been generated from package.yaml by hpack version 0.17.0. -- -- see: https://github.com/sol/hpack name: pipes-cacophony version: 0.5.0 x-revision: 1 synopsis: Pipes for Noise-secured network connections. description: A set of pipes to secure network connections with the <https://github.com/trevp/noise/blob/master/noise.md Noise> protocol. category: Cryptography homepage: https://github.com/centromere/pipes-cacophony#readme bug-reports: https://github.com/centromere/pipes-cacophony/issues maintainer: John Galt <jgalt@centromere.net> license: PublicDomain license-file: LICENSE build-type: Simple cabal-version: >= 1.10 extra-source-files: .travis.yml changelog.md LICENSE package.yaml README.md stack.yaml tests/.hlint source-repository head type: git location: https://github.com/centromere/pipes-cacophony flag build-examples description: Build examples manual: True default: False library hs-source-dirs: src default-extensions: OverloadedStrings ghc-options: -Wall build-depends: base >= 4.9 && < 4.11 , bytestring , cacophony >= 0.10 , pipes exposed-modules: Pipes.Noise other-modules: Paths_pipes_cacophony default-language: Haskell2010 executable loopback main-is: Main.hs hs-source-dirs: examples/loopback default-extensions: OverloadedStrings ghc-options: -Wall -O2 -rtsopts -threaded -with-rtsopts=-N if flag(build-examples) build-depends: base >= 4.9 && < 4.10 , bytestring , cacophony >= 0.10 , pipes , pipes-cacophony else buildable: False default-language: Haskell2010 test-suite hlint type: exitcode-stdio-1.0 main-is: hlint.hs hs-source-dirs: tests/hlint ghc-options: -Wall -O2 -rtsopts -threaded -with-rtsopts=-N build-depends: base >= 4.9 && < 4.10 , hlint default-language: Haskell2010