mirror of
https://github.com/simonmichael/hledger.git
synced 2024-11-08 07:09:28 +03:00
imp: lib: Hledger.Utils.Debug: re-export Debug.Breakpoint
And add breakpoint as a dependency and enable its GHC plugin in all the hledger packages, so that breakpoint's helpers can be used easily.
This commit is contained in:
parent
6a4680d561
commit
9584ebb439
@ -44,6 +44,8 @@ module Hledger.Utils.Debug (
|
||||
,pprint'
|
||||
,pshow
|
||||
,pshow'
|
||||
,useColorOnStdout
|
||||
,useColorOnStderr
|
||||
-- * Tracing
|
||||
,traceWith
|
||||
-- * Pretty tracing
|
||||
@ -92,9 +94,7 @@ module Hledger.Utils.Debug (
|
||||
-- ** Trace the state of hledger parsers
|
||||
,traceParse
|
||||
,dbgparse
|
||||
,module Debug.Trace
|
||||
,useColorOnStdout
|
||||
,useColorOnStderr
|
||||
-- ** Debug-logging to a file
|
||||
,dlogTrace
|
||||
,dlogTraceAt
|
||||
,dlogAt
|
||||
@ -108,6 +108,9 @@ module Hledger.Utils.Debug (
|
||||
,dlog7
|
||||
,dlog8
|
||||
,dlog9
|
||||
-- ** Re-exports
|
||||
,module Debug.Breakpoint
|
||||
,module Debug.Trace
|
||||
)
|
||||
where
|
||||
|
||||
@ -117,6 +120,7 @@ import Control.Monad.IO.Class
|
||||
import Data.List hiding (uncons)
|
||||
import qualified Data.Text as T
|
||||
import qualified Data.Text.Lazy as TL
|
||||
import Debug.Breakpoint
|
||||
import Debug.Trace
|
||||
import Hledger.Utils.Parse
|
||||
import Safe (readDef)
|
||||
|
@ -38,6 +38,7 @@ dependencies:
|
||||
- ansi-terminal >=0.9
|
||||
- array
|
||||
- blaze-markup >=0.5.1
|
||||
- breakpoint
|
||||
- bytestring
|
||||
- call-stack
|
||||
- cmdargs >=0.10
|
||||
|
@ -55,6 +55,7 @@ dependencies:
|
||||
- hledger >=1.26.99 && <1.27
|
||||
- ansi-terminal >=0.9
|
||||
- async
|
||||
- breakpoint
|
||||
- cmdargs >=0.8
|
||||
- containers >=0.5.9
|
||||
- data-default
|
||||
|
@ -106,6 +106,7 @@ library:
|
||||
- base64
|
||||
- blaze-html
|
||||
- blaze-markup
|
||||
- breakpoint
|
||||
- bytestring
|
||||
- case-insensitive
|
||||
- clientsession
|
||||
|
@ -101,6 +101,7 @@ dependencies:
|
||||
- hledger-lib >=1.26.99 && <1.27
|
||||
- aeson >=1
|
||||
- ansi-terminal >=0.9
|
||||
- breakpoint
|
||||
- bytestring
|
||||
- cmdargs >=0.10
|
||||
- containers >=0.5.9
|
||||
|
@ -10,6 +10,7 @@ packages:
|
||||
|
||||
extra-deps:
|
||||
# for hledger-lib:
|
||||
- breakpoint-0.1.0.0
|
||||
# for hledger:
|
||||
# for hledger-ui:
|
||||
- brick-1.0
|
||||
@ -20,6 +21,9 @@ nix:
|
||||
pure: false
|
||||
packages: [perl gmp ncurses zlib]
|
||||
|
||||
ghc-options:
|
||||
"$locals": -fplugin Debug.Breakpoint
|
||||
|
||||
# # for precise profiling, per https://www.tweag.io/posts/2020-01-30-haskell-profiling.html:
|
||||
# # apply-ghc-options: everything
|
||||
# # rebuild-ghc-options: true
|
||||
|
@ -14,6 +14,7 @@ packages:
|
||||
|
||||
extra-deps:
|
||||
# for hledger-lib:
|
||||
- breakpoint-0.1.0.0
|
||||
- doctest-0.20.0
|
||||
# for hledger:
|
||||
# for hledger-ui:
|
||||
@ -24,6 +25,9 @@ extra-deps:
|
||||
# for hledger-web:
|
||||
# for Shake.hs:
|
||||
|
||||
ghc-options:
|
||||
"$locals": -fplugin Debug.Breakpoint
|
||||
|
||||
# for precise profiling, per https://www.tweag.io/posts/2020-01-30-haskell-profiling.html:
|
||||
# apply-ghc-options: everything
|
||||
# rebuild-ghc-options: true
|
||||
|
@ -18,6 +18,7 @@ packages:
|
||||
|
||||
extra-deps:
|
||||
# for hledger-lib:
|
||||
- breakpoint-0.1.0.0
|
||||
# for hledger:
|
||||
# for hledger-ui:
|
||||
- brick-1.0
|
||||
@ -27,6 +28,9 @@ extra-deps:
|
||||
# for hledger-web:
|
||||
# for Shake.hs:
|
||||
|
||||
ghc-options:
|
||||
"$locals": -fplugin Debug.Breakpoint
|
||||
|
||||
# for precise profiling, per https://www.tweag.io/posts/2020-01-30-haskell-profiling.html:
|
||||
# apply-ghc-options: everything
|
||||
# rebuild-ghc-options: true
|
||||
|
Loading…
Reference in New Issue
Block a user