diff --git a/Cargo.toml b/Cargo.toml index 38c000d..cc6dbc9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,14 +1,11 @@ [workspace] -members = [ - "ncbi", - "kr2r", - "seqkmer"] +members = ["ncbi", "kr2r", "seqkmer"] resolver = "2" [profile.release] lto = true -opt-level = "s" # 或者 "z" +opt-level = "s" # 或者 "z" debug-assertions = false # panic = 'abort' codegen-units = 1 # Compile crates one after another so the compiler can optimize better -strip = true # Remove debug symbols +strip = true # Remove debug symbols diff --git a/README.md b/README.md index 4ef774f..572b747 100644 --- a/README.md +++ b/README.md @@ -105,7 +105,7 @@ This will build the kr2r and ncbi project in release mode. Next, run the example script that demonstrates how to use the `kun_peng` binary. Execute the following command from the root of the workspace: ``` sh -cargo run --release --example build_and_classify --package kr2r +cargo run --release --example build_and_classify --package kun_peng ``` This will run the build_and_classify.rs example located in the kr2r project's examples directory. @@ -124,7 +124,7 @@ kun_peng direct error: [any direct errors here] This output confirms that the `kun_peng` commands were executed successfully and the files were processed as expected. -## ncbi tool +## ncbi_dl tool #### Run the `ncbi` Example @@ -132,7 +132,7 @@ This output confirms that the `kun_peng` commands were executed successfully and Run the example script in the ncbi project to download the necessary files. Execute the following command from the root of the workspace: ``` sh -cargo run --release --example run_download --package ncbi +cargo run --release --example run_download --package ncbi_dl ``` This will run the run_download.rs example located in the ncbi project's examples directory. The script will: @@ -140,26 +140,26 @@ This will run the run_download.rs example located in the ncbi project's examples 1. Ensure the necessary directories exist. 2. Download the required files using the ncbi binary with the following commands: -- ./target/release/ncbi -d downloads gen -g archaea -- ./target/release/ncbi -d downloads tax +- ./target/release/ncbi_dl -d downloads gen -g archaea +- ./target/release/ncbi_dl -d downloads tax Example Output You should see output similar to the following: ``` txt -Executing command: /path/to/workspace/target/release/ncbi -d /path/to/workspace/downloads gen -g archaea +Executing command: /path/to/workspace/target/release/ncbi_dl -d /path/to/workspace/downloads gen -g archaea NCBI binary output: [download output here] -Executing command: /path/to/workspace/target/release/ncbi -d /path/to/workspace/downloads tax +Executing command: /path/to/workspace/target/release/ncbi_dl -d /path/to/workspace/downloads tax NCBI binary output: [download output here] ``` -The ncbi binary is used to download resources from the NCBI website. Here is the help manual for the ncbi binary: +The ncbi_dl binary is used to download resources from the NCBI website. Here is the help manual for the ncbi_dl binary: ``` sh -./target/release/ncbi -h -ncbi download resource +./target/release/ncbi_dl -h +ncbi_dl download resource -Usage: ncbi [OPTIONS] +Usage: ncbi_dl [OPTIONS] Commands: taxonomy Download taxonomy files from NCBI (alias: tax) diff --git a/ncbi/README.md b/ncbi/README.md index 9ab1165..f7a2ab1 100644 --- a/ncbi/README.md +++ b/ncbi/README.md @@ -1,12 +1,12 @@ -## ncbi tool +## ncbi_dl tool -The ncbi binary is used to download resources from the NCBI website. Here is the help manual for the ncbi binary: +The ncbi_dl binary is used to download resources from the NCBI website. Here is the help manual for the ncbi_dl binary: ``` sh -./target/release/ncbi -h -ncbi download resource +./target/release/ncbi_dl -h +ncbi_dl download resource -Usage: ncbi [OPTIONS] +Usage: ncbi_dl [OPTIONS] Commands: taxonomy Download taxonomy files from NCBI (alias: tax) diff --git a/ncbi/examples/run_download.rs b/ncbi/examples/run_download.rs index cadaf6f..4591759 100644 --- a/ncbi/examples/run_download.rs +++ b/ncbi/examples/run_download.rs @@ -9,7 +9,7 @@ fn main() { .to_path_buf(); // Run the NCBI binary to download files - let ncbi_binary = workspace_root.join("target/release/ncbi"); + let ncbi_binary = workspace_root.join("target/release/ncbi_dl"); let download_dir = workspace_root.join("downloads"); // Ensure the download directory exists fs::create_dir_all(&download_dir).expect("Failed to create download directory");