diff options
author | Gregor Kleen <pngwjpgh@users.noreply.github.com> | 2016-07-17 19:21:56 +0200 |
---|---|---|
committer | Gregor Kleen <pngwjpgh@users.noreply.github.com> | 2016-07-17 19:21:56 +0200 |
commit | 2b9ceaead3f3cd80e973cccecb9a3eebc51154f7 (patch) | |
tree | df2378943480647606b6a06f62c0f4b8b2ab406d /tprint | |
parent | ac4cf4a0a494eafe55364f816569c517684fdf32 (diff) | |
download | thermoprint-2b9ceaead3f3cd80e973cccecb9a3eebc51154f7.tar thermoprint-2b9ceaead3f3cd80e973cccecb9a3eebc51154f7.tar.gz thermoprint-2b9ceaead3f3cd80e973cccecb9a3eebc51154f7.tar.bz2 thermoprint-2b9ceaead3f3cd80e973cccecb9a3eebc51154f7.tar.xz thermoprint-2b9ceaead3f3cd80e973cccecb9a3eebc51154f7.zip |
Fixes for GHC 8.0.1
Diffstat (limited to 'tprint')
-rw-r--r-- | tprint/src/Options.hs | 4 | ||||
-rw-r--r-- | tprint/tprint.cabal | 8 |
2 files changed, 7 insertions, 5 deletions
diff --git a/tprint/src/Options.hs b/tprint/src/Options.hs index 1ad6c47..e146f91 100644 --- a/tprint/src/Options.hs +++ b/tprint/src/Options.hs | |||
@@ -26,6 +26,8 @@ import Instances () | |||
26 | import Paths_tprint (version) | 26 | import Paths_tprint (version) |
27 | import Data.Version (showVersion) | 27 | import Data.Version (showVersion) |
28 | 28 | ||
29 | import Data.Bifunctor (Bifunctor(..)) | ||
30 | |||
29 | data TPrint = TPrint | 31 | data TPrint = TPrint |
30 | { baseUrl :: BaseUrl | 32 | { baseUrl :: BaseUrl |
31 | , dryRun :: Bool | 33 | , dryRun :: Bool |
@@ -148,7 +150,7 @@ pOperation = hsubparser $ mconcat [ command "printers" cmdPrinters | |||
148 | ] | 150 | ] |
149 | 151 | ||
150 | pTPrint :: Parser TPrint | 152 | pTPrint :: Parser TPrint |
151 | pTPrint = TPrint <$> option (eitherReader parseBaseUrl) (metavar "URL" <> long "baseurl" <> short 'u' <> help "Server to interact with" <> value (BaseUrl Http "localhost" 3000) <> showDefaultWith showBaseUrl) | 153 | pTPrint = TPrint <$> option (eitherReader $ first show . parseBaseUrl) (metavar "URL" <> long "baseurl" <> short 'u' <> help "Server to interact with" <> value (BaseUrl Http "localhost" 3000 "") <> showDefaultWith showBaseUrl) |
152 | <*> switch (long "dry-run" <> short 'n' <> help "Don't send any requests that would be expected to change the servers state") | 154 | <*> switch (long "dry-run" <> short 'n' <> help "Don't send any requests that would be expected to change the servers state") |
153 | <*> pOutput | 155 | <*> pOutput |
154 | <*> pOperation | 156 | <*> pOperation |
diff --git a/tprint/tprint.cabal b/tprint/tprint.cabal index d6fc422..5fcd00b 100644 --- a/tprint/tprint.cabal +++ b/tprint/tprint.cabal | |||
@@ -2,7 +2,7 @@ | |||
2 | -- documentation, see http://haskell.org/cabal/users-guide/ | 2 | -- documentation, see http://haskell.org/cabal/users-guide/ |
3 | 3 | ||
4 | name: tprint | 4 | name: tprint |
5 | version: 1.0.0 | 5 | version: 2.0.0 |
6 | synopsis: A CLI for thermoprint-client | 6 | synopsis: A CLI for thermoprint-client |
7 | -- description: | 7 | -- description: |
8 | homepage: http://dirty-haskell.org/tags/thermoprint.html | 8 | homepage: http://dirty-haskell.org/tags/thermoprint.html |
@@ -22,9 +22,9 @@ executable tprint | |||
22 | , Options.Utils | 22 | , Options.Utils |
23 | , Instances | 23 | , Instances |
24 | -- other-extensions: | 24 | -- other-extensions: |
25 | build-depends: base >=4.8 && <4.9 | 25 | build-depends: base >=4.8 && <5 |
26 | , thermoprint-bbcode >=1.0.0 && <2 | 26 | , thermoprint-bbcode >=2.0.0 && <3 |
27 | , thermoprint-client ==0.0.* | 27 | , thermoprint-client ==1.0.* |
28 | , optparse-applicative >=0.12.1 && <1 | 28 | , optparse-applicative >=0.12.1 && <1 |
29 | , containers >=0.5.6 && <1 | 29 | , containers >=0.5.6 && <1 |
30 | , time >=1.5.0 && <2 | 30 | , time >=1.5.0 && <2 |