From afa145e6e6a2560e2f95fb486c09b392ca119354 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Sat, 25 Mar 2023 22:18:44 +0100 Subject: [PATCH] Rename --project to --package --- docs/README.md | 2 +- src/arguments.rs | 2 +- tests/scripts/gen-only.script | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/README.md b/docs/README.md index 061440f..3f76da6 100644 --- a/docs/README.md +++ b/docs/README.md @@ -101,7 +101,7 @@ Useful command-line arguments: - `--bench`: Compile and run benchmarks. Requires a nightly toolchain. - `--debug`: Build a debug executable, not an optimised one. - `--force`: Force the script to be rebuilt. Useful if you want to force a recompile with a different toolchain. -- `--project`: Generate the Cargo package and print the path to it - but don't compile or run it. Effectively "unpacks" the script into a Cargo package. +- `--package`: Generate the Cargo package and print the path to it - but don't compile or run it. Effectively "unpacks" the script into a Cargo package. - `--test`: Compile and run tests. ## Executable Scripts diff --git a/src/arguments.rs b/src/arguments.rs index f0dd41a..9b9f080 100644 --- a/src/arguments.rs +++ b/src/arguments.rs @@ -129,7 +129,7 @@ impl Args { ) .arg(Arg::new("gen_pkg_only") .help("Generate the Cargo package and print the path to it, but don't compile or run it.") - .long("project") + .long("package") .short('p') .action(ArgAction::SetTrue) .requires("script") diff --git a/tests/scripts/gen-only.script b/tests/scripts/gen-only.script index fd74f45..a420991 100755 --- a/tests/scripts/gen-only.script +++ b/tests/scripts/gen-only.script @@ -8,7 +8,7 @@ cd "$mytmpdir" printf 'println!("hello, world");' > script.rs -cd $(rust-script --project script.rs) +cd $(rust-script --package script.rs) echo "About to cargo run" cargo run -q