39 lines
1.7 KiB
Rust
39 lines
1.7 KiB
Rust
pub fn print_help() {
|
|
println!(r##"{} v{} - {}
|
|
|
|
Show help:
|
|
$ runrs -h|--help
|
|
|
|
Show template:
|
|
$ runrs -t|--template [--output script.rs]
|
|
|
|
Show scriptions:
|
|
$ runrs -l|--list
|
|
|
|
Install script:
|
|
$ runrs -i|--install <script.rs>
|
|
|
|
Run script:
|
|
$ runrs <script.rs> [arguments]
|
|
|
|
Binaries dir:
|
|
~/Library/Caches/rust-script/binaries/release/
|
|
|
|
Environment variables:
|
|
┌──────────────────────┬────────────────────────────────────────────────┐
|
|
│ Variable │ Description │
|
|
├──────────────────────┼────────────────────────────────────────────────┤
|
|
│ HOME │ User home, default from OS system │
|
|
│ RUNRS_SKIP_CACHE │ Skip compiled cached file, `bool` │
|
|
│ RUNRS_REBUILD │ Force rebuild, `bool` │
|
|
│ RUNRS_SILENT_BUILD │ Build new binary in silent mode, `bool` │
|
|
│ RUNRS_RUST_SCRIPT │ `rust_script` command line bin file │
|
|
│ RUNRS_MAX_SCRIPT_LEN │ Max script length, default 1MB │
|
|
└──────────────────────┴────────────────────────────────────────────────┘
|
|
> Type `bool`: `true`, `yes`, `on` or `1` for true, otherwise false
|
|
"##,
|
|
env!("CARGO_PKG_NAME"),
|
|
env!("CARGO_PKG_VERSION"),
|
|
env!("CARGO_PKG_DESCRIPTION")
|
|
);
|
|
} |