use crate::config::TOOL_VERSION;
pub fn is_help_flag(arg: &str) -> bool {
arg == "--help" || arg == "-h"
}
pub fn help_text() -> String {
format!(
"cargo-cgp {TOOL_VERSION}
Make Context-Generic Programming (CGP) compiler errors readable.
Usage:
cargo cgp <COMMAND> [ARGS]...
cargo-cgp <COMMAND> [ARGS]...
Commands:
check Check the current package like `cargo check`, presenting CGP errors
root-cause first. Arguments after `check` are forwarded to `cargo check`.
setup Install the pinned nightly toolchain and build the matching driver.
update Upgrade cargo-cgp to the latest published version.
Options:
-h, --help Print this help.
Run `cargo cgp check --help` to see the underlying `cargo check` options."
)
}