forked from GitHub/gf-core
Setup.hs: don't ask darcs for the version history if _darcs is not present
This is to avoid a (harmless) error message from darcs when compiling sources obtained e.g. from github.
This commit is contained in:
3
Setup.hs
3
Setup.hs
@@ -383,7 +383,8 @@ extractDarcsVersion distFlag =
|
|||||||
modname = "DarcsVersion_gf"
|
modname = "DarcsVersion_gf"
|
||||||
|
|
||||||
askDarcs =
|
askDarcs =
|
||||||
do tags <- lines `fmap` readProcess "darcs" ["show","tags"] ""
|
do flip unless (fail "no _darcs") =<< doesDirectoryExist "_darcs"
|
||||||
|
tags <- lines `fmap` readProcess "darcs" ["show","tags"] ""
|
||||||
let from = case tags of
|
let from = case tags of
|
||||||
[] -> []
|
[] -> []
|
||||||
tag:_ -> ["--from-tag="++tag]
|
tag:_ -> ["--from-tag="++tag]
|
||||||
|
|||||||
Reference in New Issue
Block a user