Skip to content
Myr

doc: fix typos

Before adoption: this commit came in with the history the project adopted, so no landing records it.

PR #1605

authored by Martin Michlmayr · committed by GitHub · parent b1e3de2 · Browse files · 11 files+14 added−14 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

11 files+14 added−14 removed

  • other:+14 added−14 removed

11 files+14 added−14 removed

modified:crates/cli/src/human.rs+1 added-1 removed
5 unmodified lines
6use regex::Regex;78/// An error that occurs when parsing a human readable size description.9///10/// This error provides a end user friendly message describing why the10/// This error provides an end user friendly message describing why the11/// description coudln't be parsed and what the expected format is.12#[derive(Clone, Debug, Eq, PartialEq)]13pub struct ParseSizeError {14 original: String,
151 unmodified lines
modified:crates/core/app.rs+2 added-2 removed
459 unmodified lines
460 self.claparg = self.claparg.alias(name);461 self462 }463464 /// Permit this flag to have values that begin with a hypen.464 /// Permit this flag to have values that begin with a hyphen.465 ///466 /// This panics if this arg is not a flag.467 fn allow_leading_hyphen(mut self) -> RGArg {468 match self.kind {
2107 unmodified lines
2576flag nor any other ripgrep flag will modify your files.25772578Capture group indices (e.g., $5) and names (e.g., $foo) are supported in the2579replacement string. Capture group indices are numbered based on the position of2580the opening paranthesis of the group, where the leftmost such group is $1. The2580the opening parenthesis of the group, where the leftmost such group is $1. The2581special $0 group corresponds to the entire match.25822583In shells such as Bash and zsh, you should wrap the pattern in single quotes2584instead of double quotes. Otherwise, capture group indices will be replaced by
448 unmodified lines
modified:crates/core/args.rs+1 added-1 removed
1539 unmodified lines
1540 /// be tracked.1541 ///1542 /// Generally, this is only enabled when explicitly requested by in the1543 /// command line arguments via the --stats flag, but this can also be1544 /// enabled implicity via the output format, e.g., for JSON Lines.1544 /// enabled implicitly via the output format, e.g., for JSON Lines.1545 fn stats(&self) -> bool {1546 self.output_kind() == OutputKind::JSON || self.is_present("stats")1547 }1548
306 unmodified lines
modified:crates/globset/src/glob.rs+1 added-1 removed
365 unmodified lines
366 Some(lit)367 }368 }369370 /// This is like `ext`, but returns an extension even if it isn't sufficent370 /// This is like `ext`, but returns an extension even if it isn't sufficient371 /// to imply a match. Namely, if an extension is returned, then it is372 /// necessary but not sufficient for a match.373 fn required_ext(&self) -> Option<String> {374 if self.opts.case_insensitive {
1147 unmodified lines
modified:crates/globset/src/lib.rs+2 added-2 removed
350 unmodified lines
351352 /// Adds the sequence number of every glob pattern that matches the given353 /// path to the vec given.354 ///355 /// `into` is is cleared before matching begins, and contains the set of355 /// `into` is cleared before matching begins, and contains the set of356 /// sequence numbers (in ascending order) after matching ends. If no globs357 /// were matched, then `into` will be empty.358 pub fn matches_into<P: AsRef<Path>>(359 &self,
5 unmodified lines
365366 /// Adds the sequence number of every glob pattern that matches the given367 /// path to the vec given.368 ///369 /// `into` is is cleared before matching begins, and contains the set of369 /// `into` is cleared before matching begins, and contains the set of370 /// sequence numbers (in ascending order) after matching ends. If no globs371 /// were matched, then `into` will be empty.372 ///373 /// This takes a Candidate as input, which can be used to amortize the
493 unmodified lines
modified:crates/ignore/src/types.rs+1 added-1 removed
132 unmodified lines
133 fn unmatched() -> Glob<'a> {134 Glob(GlobInner::UnmatchedIgnore)135 }136137 /// Return the file type defintion that matched, if one exists. A file type137 /// Return the file type definition that matched, if one exists. A file type138 /// definition always exists when a specific definition matches a file139 /// path.140 pub fn file_type_def(&self) -> Option<&FileTypeDef> {141 match self {
450 unmodified lines
modified:crates/matcher/src/interpolate.rs+1 added-1 removed
57 unmodified lines
5859/// `CaptureRef` represents a reference to a capture group inside some text.60/// The reference is either a capture group name or a number.61///62/// It is also tagged with the position in the text immediately proceding the62/// It is also tagged with the position in the text immediately proceeding the63/// capture reference.64#[derive(Clone, Copy, Debug, Eq, PartialEq)]65struct CaptureRef<'a> {66 cap: Ref<'a>,
262 unmodified lines
modified:crates/regex/src/literal.rs+1 added-1 removed
114 unmodified lines
115 Some(format!("(?-u:{})", alts.join("|")))116 } else if lit.is_empty() {117 // If we're here, then we have no LCP. No LCS. And no detected118 // inner required literals. In theory this shouldn't happen, but119 // the inner literal detector isn't as nice as we hope and doens't119 // the inner literal detector isn't as nice as we hope and doesn't120 // actually support returning a set of alternating required121 // literals. (Instead, it only returns a set where EVERY literal122 // in it is required. It cannot currently express "either P or Q123 // is required.")
305 unmodified lines
modified:crates/regex/src/matcher.rs+1 added-1 removed
251 unmodified lines
252 /// if callers want to put a limit on the amount of heap space used, then253 /// they should impose a limit on the length, in bytes, of the concrete254 /// pattern string. In particular, this is viable since this parser255 /// implementation will limit itself to heap space proportional to the256 /// lenth of the pattern string.256 /// length of the pattern string.257 ///258 /// Note that a nest limit of `0` will return a nest limit error for most259 /// patterns but not all. For example, a nest limit of `0` permits `a` but260 /// not `ab`, since `ab` requires a concatenation, which results in a nest
806 unmodified lines
modified:CHANGELOG.md+1 added-1 removed
570 unmodified lines
5715725730.8.0 (2018-02-11)574==================575This is a new minor version releae of ripgrep that satisfies several popular575This is a new minor version release of ripgrep that satisfies several popular576feature requests (config files, search compressed files, true colors), fixes577many bugs and improves the quality of life for ripgrep maintainers. This578release also includes greatly improved documentation in the form of a579[User Guide](GUIDE.md) and a [FAQ](FAQ.md).
768 unmodified lines
modified:FAQ.md+2 added-2 removed
137 unmodified lines
138</h3>139140ripgrep's `-z/--search-zip` flag will cause it to search compressed files141automatically. Currently, this supports gzip, bzip2, xz, lzma, lz4, Brotli and142Zstd. Each of these requires requires the corresponding `gzip`, `bzip2`, `xz`,142Zstd. Each of these requires the corresponding `gzip`, `bzip2`, `xz`,143`lz4`, `brotli` and `zstd` binaries to be installed on your system. (That is,144ripgrep does decompression by shelling out to another process.)145146ripgrep currently does not search archive formats, so `*.tar.gz` files, for
676 unmodified lines
823824will replace all instances of 'foo' with 'bar' in the files in which825ripgrep finds the foo pattern. The `-i` flag to sed indicates that you are826editing files in place, and `s/foo/bar/g` says that you are performing a827**s**ubstitution of the pattren `foo` for `bar`, and that you are doing this827**s**ubstitution of the pattern `foo` for `bar`, and that you are doing this828substitution **g**lobally (all occurrences of the pattern in each file).829830Note: the above command assumes that you are using GNU sed. If you are using831BSD sed (the default on macOS and FreeBSD) then you must modify the above
172 unmodified lines