mirror of
https://github.com/simonmichael/hledger.git
synced 2024-09-20 10:47:29 +03:00
chart: update for current Chart version
This commit is contained in:
parent
c6a85c4b88
commit
b8e3306819
@ -7,7 +7,6 @@ Released under GPL version 3 or later.
|
||||
|
||||
module Hledger.Chart.Main
|
||||
where
|
||||
import Control.Monad (liftM3)
|
||||
import Graphics.Rendering.Chart
|
||||
import Data.Colour
|
||||
import Data.Colour.Names
|
||||
@ -22,9 +21,7 @@ import Prelude hiding (putStr, putStrLn)
|
||||
import System.IO.UTF8 (putStr, putStrLn)
|
||||
#endif
|
||||
|
||||
import Hledger.Cli.Commands
|
||||
import Hledger.Cli.Options
|
||||
import Hledger.Cli.Tests
|
||||
import Hledger.Cli.Utils (withJournalDo)
|
||||
import Hledger.Cli.Version (progversionstr, binaryfilename)
|
||||
import Hledger.Data
|
||||
@ -76,6 +73,7 @@ chart opts args j = do
|
||||
t <- getCurrentLocalTime
|
||||
let chart = genPie opts (optsToFilterSpec opts args t) j
|
||||
renderableToPNGFile (toRenderable chart) w h filename
|
||||
return ()
|
||||
where
|
||||
filename = getOption opts ChartOutput defchartoutput
|
||||
(w,h) = parseSize $ getOption opts ChartSize defchartsize
|
||||
|
@ -46,5 +46,5 @@ executable hledger-chart
|
||||
-- ,split == 0.1.*
|
||||
-- ,time
|
||||
-- ,utf8-string >= 0.3.5 && < 0.4
|
||||
,Chart >= 0.11
|
||||
,Chart >= 0.11 && < 0.15
|
||||
,colour
|
||||
|
Loading…
Reference in New Issue
Block a user