git.iko.soy/typeable/pandoc
on master help sign in
Simplified Setup.hs by removing PostClean hooks.

Added Extra-Tmp-Files to pandoc.cabal; this does the same thing. git-svn-id: https://pandoc.googlecode.com/svn/trunk@1342 788f1e2b-df1e-0410-8736-df70ead52e1b

commit40e7280a52def5b5079b9f539f479f2bae4f1e60 authorfiddlosopher <fiddlosopher@788f1e2b-df1e-0410-8736-df70ead52e1b> dateThu 31 Jul 2008, 07:44 (18 years ago) parent66910ee
2 files changed+4−15
Setup.hs+1−15 pandoc.cabal+3
Setup.hs+1−15
@@ -10,7 +10,7 @@ import Data.List (isPrefixOf)
1010
1111main = defaultMainWithHooks myHooks
1212
13−myHooks = defaultUserHooks { postConf = myPostConf, postClean = myPostClean }
13+myHooks = defaultUserHooks { postConf = myPostConf }
1414
1515pandocPath = combine "Text" "Pandoc"
1616
@@ -47,20 +47,6 @@ fillDefaultHeadersTemplate = do
4747 return . map (combine "headers") . filter (\x -> takeExtension x == ".header")
4848 fillTemplate files "DefaultHeaders.hs" "DefaultHeaders.hs"
4949
50−-- Post-clean: remove the files generated from templates.
51−myPostClean :: Args -> CleanFlags -> PackageDescription -> Maybe LocalBuildInfo -> IO ()
52−myPostClean _ _ _ _ = do
53− putStrLn "Removing source files generated from templates:"
54− removeGeneratedFile $ joinPath [pandocPath, "ASCIIMathML.hs"]
55− removeGeneratedFile $ joinPath [pandocPath, "DefaultHeaders.hs"]
56− removeGeneratedFile $ joinPath [pandocPath, "Writers", "S5.hs"]
57−
58−-- Remove file and print message.
59−removeGeneratedFile :: FilePath -> IO ()
60−removeGeneratedFile fpath = do
61− putStrLn $ " " ++ fpath
62− removeFile fpath
63−
6450-- Write the filled template file and print an explanatory message.
6551writeTemplate :: FilePath -> String -> IO ()
6652writeTemplate outfile contents = do
pandoc.cabal+3
@@ -54,6 +54,9 @@ Extra-Source-Files: README, INSTALL, COPYRIGHT, COPYRIGHT,
5454 templates/ui/default/opera.css,
5555 templates/ui/default/outline.css,
5656 templates/ui/default/print.css
57+Extra-Tmp-Files: Text/Pandoc/ASCIIMathML.hs,
58+ Text/Pandoc/DefaultHeaders.hs,
59+ Text/Pandoc/Writers/S5.hs
5760Flag splitBase
5861 Description: Choose the new, smaller, split-up base package.
5962 Default: True