mirror of
https://github.com/nushell/nushell
synced 2025-01-26 11:55:20 +00:00
Remove pub
on some command internals (#14636)
Stumbled over unnecessary `pub` `fn action` and `struct Arguments` when reworking `into bits` in #14634 Stuff like this should be local until proven otherwise and then named approrpiately.
This commit is contained in:
parent
f2e8c391a2
commit
dc0ac8e917
3 changed files with 4 additions and 4 deletions
|
@ -1,7 +1,7 @@
|
||||||
use nu_cmd_base::input_handler::{operate, CmdArgument};
|
use nu_cmd_base::input_handler::{operate, CmdArgument};
|
||||||
use nu_engine::command_prelude::*;
|
use nu_engine::command_prelude::*;
|
||||||
|
|
||||||
pub struct Arguments {
|
struct Arguments {
|
||||||
cell_paths: Option<Vec<CellPath>>,
|
cell_paths: Option<Vec<CellPath>>,
|
||||||
compact: bool,
|
compact: bool,
|
||||||
}
|
}
|
||||||
|
@ -142,7 +142,7 @@ fn into_binary(
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn action(input: &Value, _args: &Arguments, span: Span) -> Value {
|
fn action(input: &Value, _args: &Arguments, span: Span) -> Value {
|
||||||
let value = match input {
|
let value = match input {
|
||||||
Value::Binary { .. } => input.clone(),
|
Value::Binary { .. } => input.clone(),
|
||||||
Value::Int { val, .. } => Value::binary(val.to_ne_bytes().to_vec(), span),
|
Value::Int { val, .. } => Value::binary(val.to_ne_bytes().to_vec(), span),
|
||||||
|
|
|
@ -116,7 +116,7 @@ impl Command for SubCommand {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn action(input: &Value, _args: &CellPathOnlyArgs, span: Span) -> Value {
|
fn action(input: &Value, _args: &CellPathOnlyArgs, span: Span) -> Value {
|
||||||
let value_span = input.span();
|
let value_span = input.span();
|
||||||
match input {
|
match input {
|
||||||
Value::Filesize { .. } => input.clone(),
|
Value::Filesize { .. } => input.clone(),
|
||||||
|
|
|
@ -4,7 +4,7 @@ use nu_cmd_base::input_handler::{operate, CmdArgument};
|
||||||
use nu_engine::command_prelude::*;
|
use nu_engine::command_prelude::*;
|
||||||
use nu_protocol::Config;
|
use nu_protocol::Config;
|
||||||
|
|
||||||
pub struct Arguments {
|
struct Arguments {
|
||||||
cell_paths: Option<Vec<CellPath>>,
|
cell_paths: Option<Vec<CellPath>>,
|
||||||
config: Arc<Config>,
|
config: Arc<Config>,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue