From 87b2130db07808b83060adbb778ebe42c69254a6 Mon Sep 17 00:00:00 2001 From: Casey Rodarmor Date: Fri, 17 Nov 2017 23:59:36 -0800 Subject: [PATCH] Use imperative mood in help strings (#256) --- src/run.rs | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/src/run.rs b/src/run.rs index 7098aae..59af6ad 100644 --- a/src/run.rs +++ b/src/run.rs @@ -45,6 +45,8 @@ pub fn run() { .version(concat!("v", env!("CARGO_PKG_VERSION"))) .author(env!("CARGO_PKG_AUTHORS")) .about(concat!(env!("CARGO_PKG_DESCRIPTION"), " - ", env!("CARGO_PKG_HOMEPAGE"))) + .help_message("Print help information") + .version_message("Print version information") .setting(AppSettings::ColoredHelp) .setting(AppSettings::TrailingVarArg) .arg(Arg::with_name("ARGUMENTS") @@ -55,21 +57,21 @@ pub fn run() { .takes_value(true) .possible_values(&["auto", "always", "never"]) .default_value("auto") - .help("Prints colorful output")) + .help("Print colorful output")) .arg(Arg::with_name("DRY-RUN") .long("dry-run") - .help("Prints what just would do without doing it") + .help("Print what just would do without doing it") .conflicts_with("QUIET")) .arg(Arg::with_name("DUMP") .long("dump") - .help("Prints entire justfile")) + .help("Print entire justfile")) .arg(Arg::with_name("EDIT") .short("e") .long("edit") - .help("Opens justfile with $EDITOR")) + .help("Open justfile with $EDITOR")) .arg(Arg::with_name("EVALUATE") .long("evaluate") - .help("Prints evaluated variables")) + .help("Print evaluated variables")) .arg(Arg::with_name("HIGHLIGHT") .long("highlight") .help("Highlight echoed recipe lines in bold")) @@ -77,16 +79,16 @@ pub fn run() { .short("f") .long("justfile") .takes_value(true) - .help("Uses as justfile. --working-directory must also be set") + .help("Use as justfile. --working-directory must also be set") .requires("WORKING-DIRECTORY")) .arg(Arg::with_name("LIST") .short("l") .long("list") - .help("Lists available recipes and their arguments")) + .help("List available recipes and their arguments")) .arg(Arg::with_name("QUIET") .short("q") .long("quiet") - .help("Suppresses all output") + .help("Suppress all output") .conflicts_with("DRY-RUN")) .arg(Arg::with_name("SET") .long("set") @@ -94,7 +96,7 @@ pub fn run() { .number_of_values(2) .value_names(&["VARIABLE", "VALUE"]) .multiple(true) - .help("Sets to ")) + .help("Set to ")) .arg(Arg::with_name("SHELL") .long("shell") .takes_value(true) @@ -105,10 +107,10 @@ pub fn run() { .long("show") .takes_value(true) .value_name("RECIPE") - .help("Shows information about ")) + .help("Show information about ")) .arg(Arg::with_name("SUMMARY") .long("summary") - .help("Lists names of available recipes")) + .help("List names of available recipes")) .arg(Arg::with_name("VERBOSE") .short("v") .long("verbose") @@ -117,7 +119,7 @@ pub fn run() { .short("d") .long("working-directory") .takes_value(true) - .help("Uses as working directory. --justfile must also be set") + .help("Use as working directory. --justfile must also be set") .requires("JUSTFILE")) .group(ArgGroup::with_name("EARLY-EXIT") .args(&["DUMP", "EDIT", "LIST", "SHOW", "SUMMARY", "ARGUMENTS", "EVALUATE"]))