Rename --list to --list-details

This commit is contained in:
sharkdp 2020-04-03 09:39:33 +02:00 committed by David Peter
parent da5cd12b24
commit c9dc617711
4 changed files with 11 additions and 11 deletions

View File

@ -2,8 +2,8 @@
## Features
- Add a new `-l`/`--list` option to show more details about the search results. This is basically
an alias for `--exec-batch ls -l` with some additional `ls` options.
- Add a new `-l`/`--list-details` option to show more details about the search results. This is
basically an alias for `--exec-batch ls -l` with some additional `ls` options.
This can be used in order to:
* see metadata like permissions, owner, file size, modification times (#491)
* see symlink targets (#482)

2
doc/fd.1 vendored
View File

@ -66,7 +66,7 @@ Treat the pattern as a literal string instead of a regular expression.
.B \-a, \-\-absolute\-path
Shows the full path starting from the root as opposed to relative paths.
.TP
.B \-l, \-\-list
.B \-l, \-\-list\-details
Use a detailed listing format like 'ls -l'. This is basically an alias
for '--exec-batch ls -l' with some additional 'ls' options. This can be used
to see more metadata, to show symlink targets, to achieve a deterministic

View File

@ -109,8 +109,8 @@ pub fn build_app() -> App<'static, 'static> {
.overrides_with("absolute-path"),
)
.arg(
arg("list")
.long("list")
arg("list-details")
.long("list-details")
.short("l")
.conflicts_with("absolute-path"),
)
@ -132,7 +132,7 @@ pub fn build_app() -> App<'static, 'static> {
.long("print0")
.short("0")
.overrides_with("print0")
.conflicts_with("list"),
.conflicts_with("list-details"),
)
.arg(arg("depth").long("max-depth").short("d").takes_value(true))
// support --maxdepth as well, for compatibility with rg
@ -181,7 +181,7 @@ pub fn build_app() -> App<'static, 'static> {
.allow_hyphen_values(true)
.value_terminator(";")
.value_name("cmd")
.conflicts_with("list"),
.conflicts_with("list-details"),
)
.arg(
arg("exec-batch")
@ -191,7 +191,7 @@ pub fn build_app() -> App<'static, 'static> {
.allow_hyphen_values(true)
.value_terminator(";")
.value_name("cmd")
.conflicts_with_all(&["exec", "list"]),
.conflicts_with_all(&["exec", "list-details"]),
)
.arg(
arg("exclude")
@ -351,8 +351,8 @@ fn usage() -> HashMap<&'static str, Help> {
doc!(h, "absolute-path"
, "Show absolute instead of relative paths"
, "Shows the full path starting from the root as opposed to relative paths.");
doc!(h, "list"
, "Use a detailed listing format"
doc!(h, "list-details"
, "Show details like permissions, owner, size and modification time."
, "Use a detailed listing format like 'ls -l'. This is basically an alias \
for '--exec-batch ls -l' with some additional 'ls' options. This can be used \
to see more metadata, to show symlink targets, to achieve a deterministic \

View File

@ -167,7 +167,7 @@ fn main() {
})
})
.or_else(|| {
if matches.is_present("list") {
if matches.is_present("list-details") {
let color = matches.value_of("color").unwrap_or("auto");
let color_arg = ["--color=", color].concat();