Add newlines between options
Before adoption: this commit came in with the history the project adopted, so no landing records it.
authored by David Peter · committed by David Peter · parent 55029e8 · Browse files · 1 file·+40 added−0 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
1 file+40 added−0 removed
- other:+40 added−0 removed
Provenance
- Commit
5771e74- Tree
f53ba30- Author
David Peter <mail@david-peter.de>- Committer
David Peter <mail@david-peter.de>- Parent
55029e8
1 file changed+40 added−0 removed
modified:src/cli.rs+40 added
98 unmodified lines99 considered to be hidden if their name starts with a `.` sign (dot). \100 The flag can be overridden with --no-hidden."101 )]102 pub hidden: bool,103+104 /// Do not respect .(git|fd)ignore files105 #[arg(106 long,107 short = 'I',1 unmodified line109 ignored by '.gitignore', '.ignore', '.fdignore', or the global ignore file. \110 The flag can be overridden with --ignore."111 )]112 pub no_ignore: bool,113+114 /// Do not respect .gitignore files115 #[arg(116 long,117 hide_short_help = true,118 long_help = "Show search results from files and directories that would otherwise be \119 ignored by '.gitignore' files. The flag can be overridden with --ignore-vcs."120 )]121 pub no_ignore_vcs: bool,122+123 /// Do not respect .(git|fd)ignore files in parent directories124 #[arg(125 long,126 hide_short_help = true,127 long_help = "Show search results from files and directories that would otherwise be \128 ignored by '.gitignore', '.ignore', or '.fdignore' files in parent directories."129 )]130 pub no_ignore_parent: bool,131+132 /// Do not respect the global ignore file133 #[arg(long, hide = true)]134 pub no_global_ignore_file: bool,135+136 /// Unrestricted search, alias for '--no-ignore --hidden'137 #[arg(long = "unrestricted", short = 'u', overrides_with_all(&["ignore", "no_hidden"]), action(ArgAction::Count), hide_short_help = true,138 long_help = "Perform an unrestricted search, including ignored and hidden files. This is \139 an alias for '--no-ignore --hidden'."140 )]141 rg_alias_hidden_ignore: u8,142+143 /// Case-sensitive search (default: smart case)144 #[arg(145 long,146 short = 's',2 unmodified lines149 searches, unless the pattern contains an uppercase character (smart \150 case)."151 )]152 pub case_sensitive: bool,153+154 /// Case-insensitive search (default: smart case)155 #[arg(156 long,157 short = 'i',2 unmodified lines160 searches, unless the pattern contains an uppercase character (smart \161 case)."162 )]163 pub ignore_case: bool,164+165 /// Glob-based search (default: regular expression)166 #[arg(167 long,168 short = 'g',169 conflicts_with("fixed_strings"),170 long_help = "Perform a glob-based search instead of a regular expression search."171 )]172 pub glob: bool,173+174 /// Regular-expression based search (default)175 #[arg(176 long,177 overrides_with("glob"),1 unmodified line179 long_help = "Perform a regular-expression based search (default). This can be used to \180 override --glob."181 )]182 pub regex: bool,183+184 /// Treat pattern as literal string stead of regex185 #[arg(186 long,187 short = 'F',3 unmodified lines191 that this also performs substring comparison. If you want to match on an \192 exact filename, consider using '--glob'."193 )]194 pub fixed_strings: bool,195+196 /// Show absolute instead of relative paths197 #[arg(198 long,199 short = 'a',200 long_help = "Shows the full path starting from the root as opposed to relative paths. \201 The flag can be overridden with --relative-path."202 )]203 pub absolute_path: bool,204+205 /// Use a long listing format with file metadata206 #[arg(207 long,208 short = 'l',3 unmodified lines212 used to see more metadata, to show symlink targets and to achieve a \213 deterministic sort order."214 )]215 pub list_details: bool,216+217 /// Follow symbolic links218 #[arg(219 long,220 short = 'L',2 unmodified lines223 flag, symbolic links are also traversed. \224 Flag can be overriden with --no-follow."225 )]226 pub follow: bool,227+228 /// Search full abs. path (default: filename only)229 #[arg(230 long,231 short = 'p',2 unmodified lines234 (absolute) path. Example:\n \235 fd --glob -p '**/.git/config'"236 )]237 pub full_path: bool,238+239 /// Separate search results by the null character240 #[arg(241 long = "print0",242 short = '0',2 unmodified lines245 long_help = "Separate search results by the null character (instead of newlines). \246 Useful for piping results to 'xargs'."247 )]248 pub null_separator: bool,249+250 /// Set maximum search depth (default: none)251 #[arg(252 long,253 short = 'd',2 unmodified lines256 long_help = "Limit the directory traversal to a given depth. By default, there is no \257 limit on the search depth."258 )]259 max_depth: Option<usize>,260+261 /// Only show search results starting at the given depth.262 #[arg(263 long,264 value_name = "depth",1 unmodified line266 long_help = "Only show search results starting at the given depth. \267 See also: '--max-depth' and '--exact-depth'"268 )]269 min_depth: Option<usize>,270+271 /// Only show search results at the exact given depth272 #[arg(long, value_name = "depth", hide_short_help = true, conflicts_with_all(&["max_depth", "min_depth"]),273 long_help = "Only show search results at the exact given depth. This is an alias for \274 '--min-depth <depth> --max-depth <depth>'.",275 )]276 exact_depth: Option<usize>,277+278 /// Do not traverse into directories that match the search criteria. If279 /// you want to exclude specific directories, use the '--exclude=…' option.280 #[arg(long, hide_short_help = true, conflicts_with_all(&["size", "exact_depth"]),281 long_help = "Do not traverse into directories that match the search criteria. If \282 you want to exclude specific directories, use the '--exclude=…' option.",283 )]284 pub prune: bool,285+286 /// Filter by type: file (f), directory (d), symlink (l),287 /// executable (x), empty (e), socket (s), pipe (p)288 #[arg(289 long = "type",32 unmodified lines322 fd --type empty --type directory\n \323 fd -te -td"324 )]325 pub filetype: Option<Vec<FileType>>,326+327 /// Filter by file extension328 #[arg(329 long = "extension",330 short = 'e',23 unmodified lines354 that batching might still happen due to OS restrictions on the \355 maximum length of command lines.",356 )]357 pub batch_size: usize,358+359 /// Exclude entries that match the given glob pattern360 #[arg(361 long,362 short = 'E',5 unmodified lines368 --exclude '*.pyc'\n \369 --exclude node_modules"370 )]371 pub exclude: Vec<String>,372+373 /// Add a custom ignore-file in '.gitignore' format374 #[arg(375 long,376 value_name = "path",377 hide_short_help = true,378 long_help = "Add a custom ignore-file in '.gitignore' format. These files have a low precedence."379 )]380 pub ignore_file: Vec<PathBuf>,381+382 /// When to use colors383 #[arg(384 long,385 short = 'c',2 unmodified lines388 value_name = "when",389 long_help = "Declare when to use color for the pattern match output",390 )]391 pub color: ColorWhen,392+393 /// Set number of threads to use for searching & executing (default: number394 /// of available CPU cores)395 #[arg(long, short = 'j', value_name = "num", hide_short_help = true, value_parser = 1..)]396 pub threads: Option<u32>,397+398 /// Limit results based on the size of files399 #[arg(long, short = 'S', value_parser = SizeFilter::from_string, allow_hyphen_values = true, verbatim_doc_comment, value_name = "size",400 long_help = "Limit results based on the size of files using the format <+-><NUM><UNIT>.\n \401 '+': file size must be greater than or equal to this\n \12 unmodified lines414 'gi': gibibytes\n \415 'ti': tebibytes",416 )]417 pub size: Vec<SizeFilter>,418+419 /// Milliseconds to buffer before streaming search results to console420 ///421 /// Amount of time in milliseconds to buffer, before streaming the search422 /// results to the console.423 #[arg(long, hide = true, value_parser = parse_millis)]424 pub max_buffer_time: Option<Duration>,425+426 /// Filter by file modification time (newer than)427 #[arg(428 long,429 alias("change-newer-than"),8 unmodified lines438 --change-newer-than '2018-10-27 10:00:00'\n \439 --newer 2018-10-27"440 )]441 pub changed_within: Option<String>,442+443 /// Filter by file modification time (older than)444 #[arg(445 long,446 alias("change-older-than"),7 unmodified lines454 --change-older-than 2weeks\n \455 --older 2018-10-27"456 )]457 pub changed_before: Option<String>,458+459 /// Limit number of search results460 #[arg(461 long,462 value_name = "count",463 hide_short_help = true,464 long_help = "Limit the number of search results to 'count' and quit immediately."465 )]466 max_results: Option<usize>,467+468 /// Limit search to a single result469 #[arg(470 short = '1',471 hide_short_help = true,1 unmodified line473 long_help = "Limit the search to a single result and quit immediately. \474 This is an alias for '--max-results=1'."475 )]476 max_one_result: bool,477+478 /// Print nothing, exit code 0 if match found, 1 otherwise479 #[arg(480 long,481 short = 'q',5 unmodified lines487 exit code will be 1. \488 '--has-results' can be used as an alias."489 )]490 pub quiet: bool,491+492 /// Show filesystem errors493 #[arg(494 long,495 hide_short_help = true,496 long_help = "Enable the display of filesystem errors for situations such as \497 insufficient permissions or dead symlinks."498 )]499 pub show_errors: bool,500+501 /// Change current working directory502 #[arg(503 long,504 value_name = "path",4 unmodified lines509 <path> argument or the '--search-path' option will also be resolved \510 relative to this directory."511 )]512 pub base_directory: Option<PathBuf>,513+514 /// the search pattern (a regular expression, unless '--glob' is used; optional)515 #[arg(516 default_value = "",517 hide_default_value = true,3 unmodified lines521 is considered a match. If your pattern starts with a dash (-), make sure to \522 pass '--' first, or it will be considered as a flag (fd -- '-foo')."523 )]524 pub pattern: String,525+526 /// Set path separator when printing file paths527 #[arg(528 long,529 value_name = "separator",1 unmodified line531 long_help = "Set the path separator to use when printing file paths. The default is \532 the OS-specific separator ('/' on Unix, '\\' on Windows)."533 )]534 pub path_separator: Option<String>,535+536 /// the root directories for the filesystem search (optional)537 #[arg(action = ArgAction::Append,538 value_name = "path",539 long_help = "The directory where the filesystem search is rooted (optional). If \540 omitted, search the current working directory.",541 )]542 path: Vec<PathBuf>,543+544 /// Provides paths to search as an alternative to the positional <path> argument545 #[arg(546 long,547 conflicts_with("path"),3 unmodified lines551 argument. Changes the usage to `fd [OPTIONS] --search-path <path> \552 --search-path <path2> [<pattern>]`"553 )]554 search_path: Vec<PathBuf>,555+556 /// By default, relative paths are prefixed with './' when -x/--exec,557 /// -X/--exec-batch, or -0/--print0 are given, to reduce the risk of a558 /// path starting with '-' being treated as a command line option. Use559 /// this flag to disable this behaviour.3 unmodified lines563 path starting with '-' being treated as a command line option. Use \564 this flag to disable this behaviour.",565 )]566 pub strip_cwd_prefix: bool,567+568 /// Filter by owning user and/or group569 #[cfg(unix)]570 #[arg(long, short = 'o', value_parser = OwnerFilter::from_string, value_name = "user:group",571 long_help = "Filter files by their user and/or group. \274 unmodified lines