summaryrefslogtreecommitdiffhomepage
path: root/CmdLine.hs
diff options
context:
space:
mode:
Diffstat (limited to 'CmdLine.hs')
-rw-r--r--CmdLine.hs6
1 files changed, 6 insertions, 0 deletions
diff --git a/CmdLine.hs b/CmdLine.hs
index 3d45d5a..2b494db 100644
--- a/CmdLine.hs
+++ b/CmdLine.hs
@@ -14,6 +14,7 @@ data CmdLine = CmdLine
, name :: Name
, keytype :: KeyType
, testMode :: Bool
+ , gui :: Bool
}
deriving (Show)
@@ -26,6 +27,7 @@ parse = CmdLine
<*> nameopt
<*> keytypeopt
<*> testmodeswitch
+ <*> guiswitch
where
backup = flag' Backup
( long "backup"
@@ -47,6 +49,10 @@ parse = CmdLine
( long "testmode"
<> help "Avoid using expensive cryptographic operation to secure key. Use for testing only, not with real secret keys."
)
+ guiswitch = switch
+ ( long "gui"
+ <> help "Use GUI interface for interaction. Default is to use readline interface when run in a terminal, and GUI otherwise."
+ )
get :: IO CmdLine
get = execParser opts