Remove dfr from dataframe commands (#5760)

* input and output tests

* input and output types for dfr

* expression converter

* remove deprecated command

* correct expressions

* cargo clippy

* identifier for ls

* cargo clippy

* type for head and tail expression

* modify full cell path if block
This commit is contained in:
Fernando Herrera
2022-06-12 14:18:00 -05:00
committed by GitHub
parent 2dea9e6f1f
commit 11d7d8ea1e
105 changed files with 2646 additions and 1361 deletions

View File

@ -1,36 +0,0 @@
use nu_protocol::{
ast::Call,
engine::{Command, EngineState, Stack},
Category, PipelineData, Signature,
};
#[derive(Clone)]
pub struct DataframeDeprecated;
impl Command for DataframeDeprecated {
fn name(&self) -> &str {
"dataframe"
}
fn signature(&self) -> Signature {
Signature::build(self.name()).category(Category::Deprecated)
}
fn usage(&self) -> &str {
"Deprecated command"
}
fn run(
&self,
_engine_state: &EngineState,
_stack: &mut Stack,
call: &Call,
_input: PipelineData,
) -> Result<nu_protocol::PipelineData, nu_protocol::ShellError> {
Err(nu_protocol::ShellError::DeprecatedCommand(
self.name().to_string(),
"dfr".to_string(),
call.head,
))
}
}

View File

@ -21,9 +21,3 @@ pub use str_decimal::StrDecimalDeprecated;
pub use str_find_replace::StrFindReplaceDeprecated;
pub use str_int::StrIntDeprecated;
pub use unalias::UnaliasDeprecated;
#[cfg(feature = "dataframe")]
mod dataframe;
#[cfg(feature = "dataframe")]
pub use dataframe::DataframeDeprecated;