@@ -53,6 +53,10 @@ runIdris opts = do
5353 when (ShowIncs `elem` opts) $ runIO showIncs
5454 when (ShowLibs `elem` opts) $ runIO showLibs
5555 when (ShowLibdir `elem` opts) $ runIO showLibdir
56+ case opt getPkgCheck opts of
57+ [] -> return ()
58+ fs -> do runIO $ mapM_ (checkPkg (WarnOnly `elem` opts)) fs
59+ runIO $ exitWith ExitSuccess
5660 case opt getPkgClean opts of
5761 [] -> return ()
5862 fs -> do runIO $ mapM_ cleanPkg fs
@@ -79,34 +83,57 @@ showIncs = do incFlags <- getIncFlags
7983 putStrLn incFlags
8084 exitWith ExitSuccess
8185
82−usagemsg = "Idris version " ++ ver ++ "\n" ++
83− "--------------" ++ map (\x -> '-') ver ++ "\n" ++
84− "Usage: idris [input file] [options]\n" ++
85− "Options:\n" ++
86− "\t--quiet Quiet mode (for editors)\n" ++
87− "\t--[no]colour Control REPL colour highlighting\n" ++
88− "\t--check Type check only\n" ++
89− "\t-o [file] Specify output filename\n" ++
90− "\t-i [dir] Add directory to the list of import paths\n" ++
91− "\t--ibcsubdir [dir] Write IBC files into sub directory\n" ++
92− "\t--noprelude Don't import the prelude\n" ++
93− "\t--total Require functions to be total by default\n" ++
94− "\t--warnpartial Warn about undeclared partial functions\n" ++
95− "\t--typeintype Disable universe checking\n" ++
96− "\t--log [level] Type debugging log level\n" ++
97− "\t-S Do no further compilation of code generator output\n" ++
98− "\t-c Compile to object files rather than an executable\n" ++
99− "\t--mvn Create a maven project (for Java codegen)\n" ++
100− "\t--exec [expr] Execute the expression expr in the interpreter,\n" ++
101− "\t defaulting to Main.main if none provided, and exit.\n" ++
102− "\t--ideslave Ideslave mode (for editors; in/ouput wrapped in \n" ++
103− "\t s-expressions)\n" ++
104− "\t--libdir Show library install directory and exit\n" ++
105− "\t--link Show C library directories and exit (for C linking)\n" ++
106− "\t--include Show C include directories and exit (for C linking)\n" ++
107− "\t--codegen [cg] Select code generator: C, Java, bytecode, javascript,\n" ++
108− "\t node or llvm\n" ++
109− "\t--target [triple] Select target triple (for LLVM codegen)\n" ++
110− "\t--cpu [cpu] Select target CPU (e.g. corei7 or cortex-m3) (for LLVM codegen)\n"
111−
86+usagemsghdr = "Idris version " ++ ver ++ ", (C) The Idris Community 2014"
87+
88+usagemsg = usagemsghdr ++ "\n" ++
89+ map (\x -> '-') usagemsghdr ++ "\n" ++
90+ "idris [OPTIONS] [FILE]\n\n" ++
91+ "Common flags:\n" ++
92+ "\t --install=IPKG Install Package\n" ++
93+ "\t --clean=IPKG Clean Package\n" ++
94+ "\t --build=IPKG Build Package\n" ++
95+ "\t --exec=EXPR Execute as Idris\n" ++
96+ "\t --libdir Display library directory\n" ++
97+ "\t --link Display link directory\n" ++
98+ "\t --include Display the includes directory\n" ++
99+ "\t --nobanner Suppress the banner\n" ++
100+ "\t --color Force colored output\n" ++
101+ "\t --colour Force coloured output\n" ++
102+ "\t --nocolor Disable colored output\n" ++
103+ "\t --nocolour Disable coloured output\n" ++
104+ "\t --errorcontent Undocumented\n" ++
105+ "\t --nocoverage Undocumented\n" ++
106+ "\t -o --output=FILE Specify output file\n" ++
107+ "\t --check Undocumented\n" ++
108+ "\t --total Require functions to be total by default\n" ++
109+ "\t --partial Undocumented\n" ++
110+ "\t --warnpartial Warn about undeclared partial functions.\n" ++
111+ "\t --warn Undocumented\n" ++
112+ "\t --typecase Undocumented\n" ++
113+ "\t --typeintype Undocumented\n" ++
114+ "\t --nobasepkgs Undocumented\n" ++
115+ "\t --noprelude Undocumented\n" ++
116+ "\t --nobuiltins Undocumented\n" ++
117+ "\t -O --level=LEVEL Undocumented\n" ++
118+ "\t -i --idrispath=DIR Add directory to the list of import paths\n" ++
119+ "\t --package=ITEM Undocumented\n" ++
120+ "\t --ibcsubdir=FILE Write IBC files into sub directory\n" ++
121+ "\t --codegen=TARGET Select code generator: C, Java, bytecode," ++
122+ "\t javascript, node, or llvm\n" ++
123+ "\t --mvn Create a maven project (for Java codegen)\n" ++
124+ "\t --cpu=CPU Select tartget CPU e.g. corei& or cortex-m3" ++
125+ "\t (for LLVM codegen)\n" ++
126+ "\t --target=TRIPLE Select target triple (for llvm codegen)\n" ++
127+ "\t -S --codegenonly Do no further compilation of code generator output\n" ++
128+ "\t -c --compileonly Compile to object fules rather than an executable\n" ++
129+ "\t -X --extension=ITEM undocumented\n" ++
130+ "\t --dumpdefuns Undocumented\n" ++
131+ "\t --dumpcases Undocumented\n" ++
132+ "\t --log=LEVEL --loglevel Type Debugging log level\n" ++
133+ "\t --ideslave Undocumented\n" ++
134+ "\t --client Undocumented\n" ++
135+ "\t -h --help Display help message\n" ++
136+ "\t -v --version Print version information\n" ++
137+ "\t -V --Verbose Loud verbosity\n" ++
138+ "\t -q --quiet Quiet verbosity\n"
112139