summaryrefslogtreecommitdiff
path: root/Pancake.hs
diff options
context:
space:
mode:
authordefanor <defanor@uberspace.net>2017-12-12 23:42:10 +0300
committerdefanor <defanor@uberspace.net>2017-12-12 23:42:10 +0300
commit3c03b674fbec2dddce744365ddc6b96daf398864 (patch)
tree97bd549969783a19feecad785813236bdd31c83f /Pancake.hs
parent49772469e722419764377ad9449520512626c407 (diff)
Use dynamic program name in the --help message
Diffstat (limited to 'Pancake.hs')
-rw-r--r--Pancake.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Pancake.hs b/Pancake.hs
index 550dbb3..55bdf8d 100644
--- a/Pancake.hs
+++ b/Pancake.hs
@@ -354,4 +354,6 @@ main = do
([], [], []) -> run False
([OEmbedded], [], []) -> run True
([OVersion], [], []) -> putStrLn $ "pancake " ++ showVersion version
- _ -> putStrLn $ usageInfo "Usage: pancake [option ...]" options
+ _ -> do
+ p <- getProgName
+ putStrLn $ usageInfo ("Usage: " ++ p ++ " [option ...]") options