diff --git a/crates/nu-command/src/filesystem/ls.rs b/crates/nu-command/src/filesystem/ls.rs index f90f1ab03..188b04663 100644 --- a/crates/nu-command/src/filesystem/ls.rs +++ b/crates/nu-command/src/filesystem/ls.rs @@ -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) } diff --git a/crates/nu-command/src/filters/zip.rs b/crates/nu-command/src/filters/zip.rs index 7ffe268a1..7919cefc7 100644 --- a/crates/nu-command/src/filters/zip.rs +++ b/crates/nu-command/src/filters/zip.rs @@ -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, + }, ] }