diff options
author | Ryan Dahl <ry@tinyclouds.org> | 2019-02-27 00:14:10 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-02-27 00:14:10 -0500 |
commit | 33a6409db982d4ee9012cf7eede8f2fb8519f568 (patch) | |
tree | 1a88bdfa4a237fd7e6913b2efcc8730b7348ca89 /src | |
parent | e7e4cb037d01bf9289e8467cb65f123e82a95c60 (diff) |
Add NO_COLOR to CLI usage (#1843)
Diffstat (limited to 'src')
-rw-r--r-- | src/flags.rs | 33 |
1 files changed, 17 insertions, 16 deletions
diff --git a/src/flags.rs b/src/flags.rs index 5f6492c46..376e0ab95 100644 --- a/src/flags.rs +++ b/src/flags.rs @@ -39,7 +39,8 @@ pub fn get_usage(opts: &Options) -> String { format!( "Usage: deno script.ts {} Environment variables: - DENO_DIR Set deno's base directory.", + DENO_DIR Set deno's base directory + NO_COLOR Set to disable color", opts.usage("") ) } @@ -149,22 +150,22 @@ pub fn set_flags( // TODO(kevinkassimo): v8_set_flags intercepts '-help' with single '-' // Resolve that and then uncomment line below (enabling Go style -long-flag) // opts.long_only(true); - opts.optflag("", "allow-read", "Allow file system read access."); - opts.optflag("", "allow-write", "Allow file system write access."); - opts.optflag("", "allow-net", "Allow network access."); - opts.optflag("", "allow-env", "Allow environment access."); - opts.optflag("", "allow-run", "Allow running subprocesses."); - opts.optflag("A", "allow-all", "Allow all permissions."); - opts.optflag("", "recompile", "Force recompilation of TypeScript code."); - opts.optflag("h", "help", "Print this message."); - opts.optflag("D", "log-debug", "Log debug output."); - opts.optflag("v", "version", "Print the version."); - opts.optflag("r", "reload", "Reload cached remote resources."); - opts.optflag("", "v8-options", "Print V8 command line options."); - opts.optflag("", "types", "Print runtime TypeScript declarations."); - opts.optflag("", "prefetch", "Prefetch the dependencies."); + opts.optflag("", "allow-read", "Allow file system read access"); + opts.optflag("", "allow-write", "Allow file system write access"); + opts.optflag("", "allow-net", "Allow network access"); + opts.optflag("", "allow-env", "Allow environment access"); + opts.optflag("", "allow-run", "Allow running subprocesses"); + opts.optflag("A", "allow-all", "Allow all permissions"); + opts.optflag("", "recompile", "Force recompilation of TypeScript code"); + opts.optflag("h", "help", "Print this message"); + opts.optflag("D", "log-debug", "Log debug output"); + opts.optflag("v", "version", "Print the version"); + opts.optflag("r", "reload", "Reload cached remote resources"); + opts.optflag("", "v8-options", "Print V8 command line options"); + opts.optflag("", "types", "Print runtime TypeScript declarations"); + opts.optflag("", "prefetch", "Prefetch the dependencies"); opts.optflag("", "info", "Show source file related info"); - opts.optflag("", "fmt", "Format code."); + opts.optflag("", "fmt", "Format code"); let mut flags = DenoFlags::default(); |