forked from extern/nushell
parent
d43f4253e8
commit
76482cc1b2
@ -24,7 +24,7 @@ impl Command for QueryDb {
|
|||||||
SyntaxShape::String,
|
SyntaxShape::String,
|
||||||
"SQL to execute against the database",
|
"SQL to execute against the database",
|
||||||
)
|
)
|
||||||
.category(Category::Custom("database".into()))
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -17,7 +17,7 @@ impl Command for SchemaDb {
|
|||||||
fn signature(&self) -> Signature {
|
fn signature(&self) -> Signature {
|
||||||
Signature::build(self.name())
|
Signature::build(self.name())
|
||||||
.input_output_types(vec![(Type::Any, Type::Any)])
|
.input_output_types(vec![(Type::Any, Type::Any)])
|
||||||
.category(Category::Custom("database".into()))
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -31,7 +31,7 @@ impl Command for StorCreate {
|
|||||||
Some('c'),
|
Some('c'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -31,7 +31,7 @@ impl Command for StorDelete {
|
|||||||
Some('w'),
|
Some('w'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -25,7 +25,7 @@ impl Command for StorExport {
|
|||||||
Some('f'),
|
Some('f'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -25,7 +25,7 @@ impl Command for StorImport {
|
|||||||
Some('f'),
|
Some('f'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -31,7 +31,7 @@ impl Command for StorInsert {
|
|||||||
Some('d'),
|
Some('d'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -20,7 +20,7 @@ impl Command for StorOpen {
|
|||||||
Type::Custom("sqlite-in-memory".into()),
|
Type::Custom("sqlite-in-memory".into()),
|
||||||
)])
|
)])
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -17,7 +17,7 @@ impl Command for StorReset {
|
|||||||
Signature::build("stor reset")
|
Signature::build("stor reset")
|
||||||
.input_output_types(vec![(Type::Nothing, Type::Table(vec![]))])
|
.input_output_types(vec![(Type::Nothing, Type::Table(vec![]))])
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -15,7 +15,7 @@ impl Command for Stor {
|
|||||||
|
|
||||||
fn signature(&self) -> Signature {
|
fn signature(&self) -> Signature {
|
||||||
Signature::build("stor")
|
Signature::build("stor")
|
||||||
.category(Category::Strings)
|
.category(Category::Database)
|
||||||
.input_output_types(vec![(Type::Nothing, Type::String)])
|
.input_output_types(vec![(Type::Nothing, Type::String)])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ impl Command for StorUpdate {
|
|||||||
Some('w'),
|
Some('w'),
|
||||||
)
|
)
|
||||||
.allow_variants_without_examples(true)
|
.allow_variants_without_examples(true)
|
||||||
.category(Category::Math)
|
.category(Category::Database)
|
||||||
}
|
}
|
||||||
|
|
||||||
fn usage(&self) -> &str {
|
fn usage(&self) -> &str {
|
||||||
|
@ -46,6 +46,7 @@ pub enum Category {
|
|||||||
Conversions,
|
Conversions,
|
||||||
Core,
|
Core,
|
||||||
Custom(String),
|
Custom(String),
|
||||||
|
Database,
|
||||||
Date,
|
Date,
|
||||||
Debug,
|
Debug,
|
||||||
Default,
|
Default,
|
||||||
@ -78,6 +79,7 @@ impl std::fmt::Display for Category {
|
|||||||
Category::Conversions => "conversions",
|
Category::Conversions => "conversions",
|
||||||
Category::Core => "core",
|
Category::Core => "core",
|
||||||
Category::Custom(name) => name,
|
Category::Custom(name) => name,
|
||||||
|
Category::Database => "database",
|
||||||
Category::Date => "date",
|
Category::Date => "date",
|
||||||
Category::Debug => "debug",
|
Category::Debug => "debug",
|
||||||
Category::Default => "default",
|
Category::Default => "default",
|
||||||
|
Loading…
Reference in New Issue
Block a user