X-Git-Url: http://gitweb.michael.orlitzky.com/?p=email-validator.git;a=blobdiff_plain;f=src%2FCommandLine.hs;h=405ded8ef9597cb181e986b4d31240a6594a9e9e;hp=a7507df6a381a5365e7328aa8c3333158fac4c6b;hb=d9cf306292f2bfaa00b4773737b67de7f4ecf983;hpb=e986eafc21f9225bef296d13d143d096732bc7f9 diff --git a/src/CommandLine.hs b/src/CommandLine.hs index a7507df..405ded8 100644 --- a/src/CommandLine.hs +++ b/src/CommandLine.hs @@ -19,7 +19,8 @@ import ExitCodes -- stdin/stdout. data Args = Args { accept_a :: Bool, input_file :: Maybe FilePath, - output_file :: Maybe FilePath } + output_file :: Maybe FilePath, + rfc5322 :: Bool } deriving (Show, Data, Typeable) description :: String @@ -43,12 +44,17 @@ output_file_help :: String output_file_help = "Path to the output file (default: stdout)" +rfc5322_help :: String +rfc5322_help = + "Validate according to RFC 5322 (incredibly lenient)." + arg_spec :: Mode (CmdArgs Args) arg_spec = cmdArgsMode $ Args { accept_a = def &= help accept_a_help, input_file = def &= typFile &= help input_file_help, - output_file = def &= typFile &= help output_file_help } + output_file = def &= typFile &= help output_file_help, + rfc5322 = def &= help rfc5322_help } &= program program_name &= summary my_summary &= details [description]