Skip to content

Commit 825c633

Browse files
committed
Remove usage of deprecated prettyprinting functions
1 parent 684081f commit 825c633

File tree

2 files changed

+8
-13
lines changed

2 files changed

+8
-13
lines changed

executable/Main.hs

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,11 @@ main = do
105105
]
106106
)
107107
<> header (mconcat ["pandoc-plot ", V.showVersion pandocPlotVersion, " - generate figures directly in documents"])
108-
<> footerDoc (Just footer')
108+
<> footerDoc ( Just $ P.vsep
109+
[ "More information can be found via the manual (pandoc-plot --manual) or the"
110+
, "repository README, located at https://github.com/LaurentRDC/pandoc-plot"
111+
]
112+
)
109113
)
110114

111115
optparse = do
@@ -286,7 +290,7 @@ showAvailableToolkits mfp = do
286290
putStrLn $ "Toolkit: " <> show tk
287291
when avail $ do
288292
exe <- runPlotM Nothing conf $ executable tk
289-
putStrLn $ " Executable: " <> (pathToExe exe)
293+
putStrLn $ " Executable: " <> pathToExe exe
290294
putStrLn $ " Code block trigger: " <> (unpack . cls $ tk)
291295
putStrLn $ " Supported save formats: " <> (mconcat . intersperse ", " . fmap show $ supportedSaveFormats tk)
292296
putStrLn mempty
@@ -318,12 +322,3 @@ showManPage = do
318322
manualPath <- (</> "pandoc-plot-manual.html") <$> getTemporaryDirectory
319323
TIO.writeFile manualPath $(embedManualHtml)
320324
openFile ("file:///" <> manualPath)
321-
322-
-- | Use Doc type directly because of newline formatting
323-
footer' :: P.Doc
324-
footer' =
325-
mconcat
326-
[ P.text "More information can be found via the manual (pandoc-plot --manual) or the",
327-
P.line,
328-
P.text "repository README, located at https://github.com/LaurentRDC/pandoc-plot"
329-
]

pandoc-plot.cabal

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,11 @@ executable pandoc-plot
138138
, directory
139139
, filepath
140140
, gitrev >= 1 && < 2
141-
, optparse-applicative >= 0.14 && < 1
141+
, optparse-applicative >= 0.14 && < 0.19
142142
, pandoc
143143
, pandoc-plot
144144
, pandoc-types >= 1.21 && <2
145-
, template-haskell > 2.7 && < 3
145+
, template-haskell > 2.7 && <3
146146
, typed-process
147147
, text
148148
default-language: Haskell2010

0 commit comments

Comments
 (0)