packages feed

ansi-wl-pprint 0.6.8.1 → 0.6.8.2

raw patch · 4 files changed

+53/−44 lines, 4 filesdep +ansi-wl-pprintdep ~ansi-terminaldep ~basedep ~semigroupsnew-uploaderPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependencies added: ansi-wl-pprint

Dependency ranges changed: ansi-terminal, base, semigroups

API changes (from Hackage documentation)

- Text.PrettyPrint.ANSI.Leijen: class Pretty a where prettyList = list . map pretty
+ Text.PrettyPrint.ANSI.Leijen: class Pretty a
- Text.PrettyPrint.ANSI.Leijen.Internal: class Pretty a where prettyList = list . map pretty
+ Text.PrettyPrint.ANSI.Leijen.Internal: class Pretty a

Files

+ Changelog.md view
@@ -0,0 +1,3 @@+## 0.6.8.2++- Allow `ansi-terminal-0.8`
− Text/PrettyPrint/ANSI/Example.hs
@@ -1,24 +0,0 @@-module Main (main) where--import Text.PrettyPrint.ANSI.Leijen--import System.IO---main :: IO ()-main = do-    -- Going directly to the console is portable across Unix and Windows...-    putDoc $ red (text "Red") <> comma <+> white (text "white") <+> text "and" <+> blue (text "blue") <> char '!' <> linebreak-    putDoc $ blue (text "Nested" <+> dullyellow (text "colors") <+> text "example") <> linebreak-    hPutDoc stdout $ onred (text "Red") <> comma <+> onwhite (text "white") <+> text "and" <+> onblue (text "blue") <> char '!' <> linebreak-    hPutDoc stdout $ onblue (text "Nested" <+> ondullyellow (text "colors") <+> text "example") <> linebreak-    -    -- ...but going via a string will only preserve formatting information information on Unix-    putStr $ show $ green (text "I will be green on Unix but uncolored on Windows") <> linebreak-    -    -- Let's see some non-color formatting:-    putDoc $ text "We can do" <+> bold (text "boldness") <> text ", if your terminal supports it, and even perhaps" <+> underline (text "underlining") <> linebreak--    -- Just a little test of the formatting removal:-    putDoc $ text "There is a handy utility called 'plain' to" <+> plain (bold $ text "remove formatting") <+>-              plain (text "if you need to e.g. support" <+> red (text "non-ANSI") <+> text "terminals")
ansi-wl-pprint.cabal view
@@ -1,51 +1,57 @@ name:                ansi-wl-pprint-version:             0.6.8.1-cabal-version:       >= 1.6+version:             0.6.8.2+cabal-version:       >= 1.10 category:            User Interfaces, Text synopsis:            The Wadler/Leijen Pretty Printer for colored ANSI terminal output-description:         This is a pretty printing library based on Wadler's paper "A Prettier Printer". It has been enhanced with support for ANSI terminal colored output using the ansi-terminal package.+description:         {++This is a pretty printing library based on Wadler's paper ["A Prettier Printer"](https://homepages.inf.ed.ac.uk/wadler/papers/prettier/prettier.pdf). It has been enhanced with support for ANSI terminal colored output using the [ansi-terminal](https://hackage.haskell.org/package/ansi-terminal) package.++} license:             BSD3 license-file:        LICENSE-extra-source-files:  README.md+extra-source-files:  README.md Changelog.md author:              Daan Leijen, Max Bolingbroke maintainer:          Edward Kmett <ekmett@gmail.com> bug-reports:         http://github.com/ekmett/ansi-wl-pprint/issues homepage:            http://github.com/ekmett/ansi-wl-pprint build-type:          Simple-tested-with:         GHC==7.4.2, GHC==7.6.3, GHC==7.8.4, GHC==7.10.2, GHC==8.0.1+tested-with:         GHC==7.4.2, GHC==7.6.3, GHC==7.8.4, GHC==7.10.3, GHC==8.0.2, GHC==8.2.1, GHC==8.4.1, GHC==8.5.*  source-repository head   type: git-  location: git://github.com/ekmett/ansi-wl-pprint.git--flag NewBase-  description:    UNUSED! This flag was once there for compatibility reasons.-  default:        True+  location: https://github.com/ekmett/ansi-wl-pprint.git  flag Example   description:    Build the example application   default:        False-+  manual:         True  library+  default-language: Haskell2010+  hs-source-dirs: .   exposed-modules: Text.PrettyPrint.ANSI.Leijen                  , Text.PrettyPrint.ANSI.Leijen.Internal   ghc-options: -Wall -fno-warn-name-shadowing -fno-warn-unused-matches +  -- See https://ghc.haskell.org/trac/ghc/wiki/Migration/8.0#base-4.9.0.0   if impl(ghc >= 8.0)-    ghc-options: -Wcompat+    ghc-options: -Wcompat -Wnoncanonical-monad-instances -Wnoncanonical-monadfail-instances   else     -- see also notes in Text.PrettyPrint.ANSI.Leijen     build-depends: semigroups >= 0.1 && < 0.19 -  build-depends: ansi-terminal >= 0.4.0 && < 0.7-  build-depends:  base >= 4.5 && < 5+  build-depends: ansi-terminal >= 0.4.0 && < 0.9+  build-depends: base >= 4.5 && < 5  executable ansi-wl-pprint-example-  main-is: Text/PrettyPrint/ANSI/Example.hs--  build-depends: ansi-terminal >= 0.4.0 && < 0.7-  build-depends:  base >= 4.5 && < 5+  default-language: Haskell2010+  hs-source-dirs: src-exe+  main-is: Example.hs -  if !flag(example)-    buildable:      False+  if flag(example)+    build-depends: ansi-wl-pprint+    -- dependencies whose constraints are inherited via lib:ansi-wl-pprint+    build-depends: base, ansi-terminal+  else+    buildable: False
+ src-exe/Example.hs view
@@ -0,0 +1,24 @@+module Main (main) where++import Text.PrettyPrint.ANSI.Leijen++import System.IO+++main :: IO ()+main = do+    -- Going directly to the console is portable across Unix and Windows...+    putDoc $ red (text "Red") <> comma <+> white (text "white") <+> text "and" <+> blue (text "blue") <> char '!' <> linebreak+    putDoc $ blue (text "Nested" <+> dullyellow (text "colors") <+> text "example") <> linebreak+    hPutDoc stdout $ onred (text "Red") <> comma <+> onwhite (text "white") <+> text "and" <+> onblue (text "blue") <> char '!' <> linebreak+    hPutDoc stdout $ onblue (text "Nested" <+> ondullyellow (text "colors") <+> text "example") <> linebreak+    +    -- ...but going via a string will only preserve formatting information information on Unix+    putStr $ show $ green (text "I will be green on Unix but uncolored on Windows") <> linebreak+    +    -- Let's see some non-color formatting:+    putDoc $ text "We can do" <+> bold (text "boldness") <> text ", if your terminal supports it, and even perhaps" <+> underline (text "underlining") <> linebreak++    -- Just a little test of the formatting removal:+    putDoc $ text "There is a handy utility called 'plain' to" <+> plain (bold $ text "remove formatting") <+>+              plain (text "if you need to e.g. support" <+> red (text "non-ANSI") <+> text "terminals")