mirror of
https://github.com/nushell/nushell.git
synced 2025-08-19 10:52:54 +02:00
mv -> More organized method definitions.
This commit is contained in:
@@ -17,16 +17,6 @@ pub struct MoveArgs {
|
||||
}
|
||||
|
||||
impl PerItemCommand for Move {
|
||||
fn run(
|
||||
&self,
|
||||
call_info: &CallInfo,
|
||||
_registry: &CommandRegistry,
|
||||
shell_manager: &ShellManager,
|
||||
_input: Tagged<Value>,
|
||||
) -> Result<VecDeque<ReturnValue>, ShellError> {
|
||||
call_info.process(shell_manager, mv)?.run()
|
||||
}
|
||||
|
||||
fn name(&self) -> &str {
|
||||
"mv"
|
||||
}
|
||||
@@ -37,6 +27,16 @@ impl PerItemCommand for Move {
|
||||
.required("destination", SyntaxType::Path)
|
||||
.named("file", SyntaxType::Any)
|
||||
}
|
||||
|
||||
fn run(
|
||||
&self,
|
||||
call_info: &CallInfo,
|
||||
_registry: &CommandRegistry,
|
||||
shell_manager: &ShellManager,
|
||||
_input: Tagged<Value>,
|
||||
) -> Result<VecDeque<ReturnValue>, ShellError> {
|
||||
call_info.process(shell_manager, mv)?.run()
|
||||
}
|
||||
}
|
||||
|
||||
pub fn mv(
|
||||
|
Reference in New Issue
Block a user