summaryrefslogtreecommitdiff
path: root/pandoc-cli/pandoc-cli.cabal
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2022-09-30 15:57:43 -0700
committerJohn MacFarlane <jgm@berkeley.edu>2022-09-30 16:46:39 -0700
commitaa0e9c4d6e0de2101527d0a37f082af594783601 (patch)
treee00caf490dc958c22ffb570774e6befbc6609bfb /pandoc-cli/pandoc-cli.cabal
parent2bca1315cee6e2ac0bfffb6c9993b4f95c3bee4e (diff)
Move `--version` handling to pandoc-cli.
Print flag settings (lua, server) and versions of all relevant packages. Add suffix for nightly builds. Move `nightly` flag from pandoc to pandoc-cli. Closes #8339.
Diffstat (limited to 'pandoc-cli/pandoc-cli.cabal')
-rw-r--r--pandoc-cli/pandoc-cli.cabal16
1 files changed, 16 insertions, 0 deletions
diff --git a/pandoc-cli/pandoc-cli.cabal b/pandoc-cli/pandoc-cli.cabal
index 82437d441..e43a4b7db 100644
--- a/pandoc-cli/pandoc-cli.cabal
+++ b/pandoc-cli/pandoc-cli.cabal
@@ -30,6 +30,10 @@ flag server
Description: Include support for running pandoc as an HTTP server.
Default: True
+flag nightly
+ Description: Add '-nightly-COMPILEDATE' to the output of '--version'.
+ Default: False
+
common common-options
default-language: Haskell2010
other-extensions: OverloadedStrings
@@ -63,8 +67,20 @@ executable pandoc
main-is: pandoc.hs
buildable: True
build-depends: pandoc >= 3.0,
+ text,
+ -- The following are needed only to get cabal to
+ -- define the VERSION_xxx macros. They are all
+ -- transitive dependencies anyway.
+ texmath,
+ skylighting,
+ pandoc-types,
+ ipynb,
+ citeproc
other-modules: PandocCLI.Lua
, PandocCLI.Server
+ if flag(nightly)
+ cpp-options: -DNIGHTLY
+ build-depends: template-haskell
if flag(server)
build-depends: pandoc-server >= 0.1 && < 0.2,
wai-extra >= 3.0.24,