1
0
mirror of https://github.com/nushell/nushell.git synced 2025-01-14 18:28:15 +01:00

Slight edits to ls and zip's help text ()

This commit is contained in:
Leon 2022-12-30 01:24:08 +10:00 committed by GitHub
parent 8c6a0f68d4
commit 6ac26094da
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 4 deletions
crates/nu-command/src
filesystem
filters

View File

@ -28,7 +28,7 @@ impl Command for Ls {
}
fn usage(&self) -> &str {
"List the files in a directory."
"List the filenames, sizes, and modification times of items in a directory."
}
fn search_terms(&self) -> Vec<&str> {
@ -54,7 +54,7 @@ impl Command for Ls {
.switch("full-paths", "display paths as absolute paths", Some('f'))
.switch(
"du",
"Display the apparent directory size in place of the directory metadata size",
"Display the apparent directory size (\"disk usage\") in place of the directory metadata size",
Some('d'),
)
.switch(
@ -62,7 +62,7 @@ impl Command for Ls {
"List the specified directory itself instead of its contents",
Some('D'),
)
.switch("mime-type", "Show mime-type in type column", Some('m'))
.switch("mime-type", "Show mime-type in type column instead of 'file' (based on filenames only; files' contents are not examined)", Some('m'))
.category(Category::FileSystem)
}

View File

@ -70,12 +70,17 @@ impl Command for Zip {
},
Example {
example: "1..3 | zip 4..6",
description: "Zip two streams",
description: "Zip two ranges",
result: Some(Value::List {
vals: vec![test_row_1, test_row_2, test_row_3],
span: Span::test_data(),
}),
},
Example {
example: "glob *.ogg | zip ['bang.ogg', 'fanfare.ogg', 'laser.ogg'] | each { mv $in.0 $in.1 }",
description: "Rename .ogg files to match an existing list of filenames",
result: None,
},
]
}