Rename .copy -> .clone

This commit is contained in:
PThorpe92
2025-08-04 20:29:50 -04:00
parent 7e42b97b93
commit f75eaee886
4 changed files with 7 additions and 7 deletions

View File

@@ -713,7 +713,7 @@ impl Limbo {
HeadersMode::Off => false,
};
}
Command::Copy(args) => {
Command::Clone(args) => {
if let Err(e) = self.conn.copy_db(&args.output_file) {
let _ = self.writeln(e.to_string());
}

View File

@@ -144,7 +144,7 @@ pub struct HeadersArgs {
}
#[derive(Debug, Clone, Args)]
pub struct CopyArgs {
pub struct CloneArgs {
pub output_file: String,
}

View File

@@ -10,7 +10,7 @@ use clap::Parser;
use import::ImportArgs;
use crate::{
commands::args::CopyArgs,
commands::args::CloneArgs,
input::{AFTER_HELP_MSG, BEFORE_HELP_MSG},
};
@@ -89,8 +89,8 @@ pub enum Command {
/// Toggle column headers on/off in list mode
#[command(name = "headers", display_name = ".headers")]
Headers(HeadersArgs),
#[command(name = "copy", display_name = ".copy")]
Copy(CopyArgs),
#[command(name = "clone", display_name = ".clone")]
Clone(CloneArgs),
}
const _HELP_TEMPLATE: &str = "{before-help}{name}

View File

@@ -239,8 +239,8 @@ pub const AFTER_HELP_MSG: &str = r#"Usage Examples:
17. To turn off column headers in list mode:
.headers off
18. To copy the open database to another file:
.copy output_file.db
18. To clone the open database to another file:
.clone output_file.db
Note:
- All SQL commands must end with a semicolon (;).