1
0
mirror of https://github.com/BurntSushi/ripgrep.git synced 2025-01-03 05:10:12 +02:00

doc: fix typos

PR #1605
This commit is contained in:
Martin Michlmayr 2020-06-04 21:06:09 +08:00 committed by GitHub
parent b1e3de246c
commit 1b2c1dc675
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 14 additions and 14 deletions

View File

@ -572,7 +572,7 @@ Bug fixes:
0.8.0 (2018-02-11)
==================
This is a new minor version releae of ripgrep that satisfies several popular
This is a new minor version release of ripgrep that satisfies several popular
feature requests (config files, search compressed files, true colors), fixes
many bugs and improves the quality of life for ripgrep maintainers. This
release also includes greatly improved documentation in the form of a

4
FAQ.md
View File

@ -139,7 +139,7 @@ How do I search compressed files?
ripgrep's `-z/--search-zip` flag will cause it to search compressed files
automatically. Currently, this supports gzip, bzip2, xz, lzma, lz4, Brotli and
Zstd. Each of these requires requires the corresponding `gzip`, `bzip2`, `xz`,
Zstd. Each of these requires the corresponding `gzip`, `bzip2`, `xz`,
`lz4`, `brotli` and `zstd` binaries to be installed on your system. (That is,
ripgrep does decompression by shelling out to another process.)
@ -824,7 +824,7 @@ rg foo --files-with-matches | xargs sed -i 's/foo/bar/g'
will replace all instances of 'foo' with 'bar' in the files in which
ripgrep finds the foo pattern. The `-i` flag to sed indicates that you are
editing files in place, and `s/foo/bar/g` says that you are performing a
**s**ubstitution of the pattren `foo` for `bar`, and that you are doing this
**s**ubstitution of the pattern `foo` for `bar`, and that you are doing this
substitution **g**lobally (all occurrences of the pattern in each file).
Note: the above command assumes that you are using GNU sed. If you are using

View File

@ -7,7 +7,7 @@ use regex::Regex;
/// An error that occurs when parsing a human readable size description.
///
/// This error provides a end user friendly message describing why the
/// This error provides an end user friendly message describing why the
/// description coudln't be parsed and what the expected format is.
#[derive(Clone, Debug, Eq, PartialEq)]
pub struct ParseSizeError {

View File

@ -461,7 +461,7 @@ impl RGArg {
self
}
/// Permit this flag to have values that begin with a hypen.
/// Permit this flag to have values that begin with a hyphen.
///
/// This panics if this arg is not a flag.
fn allow_leading_hyphen(mut self) -> RGArg {
@ -2577,7 +2577,7 @@ flag nor any other ripgrep flag will modify your files.
Capture group indices (e.g., $5) and names (e.g., $foo) are supported in the
replacement string. Capture group indices are numbered based on the position of
the opening paranthesis of the group, where the leftmost such group is $1. The
the opening parenthesis of the group, where the leftmost such group is $1. The
special $0 group corresponds to the entire match.
In shells such as Bash and zsh, you should wrap the pattern in single quotes

View File

@ -1541,7 +1541,7 @@ impl ArgMatches {
///
/// Generally, this is only enabled when explicitly requested by in the
/// command line arguments via the --stats flag, but this can also be
/// enabled implicity via the output format, e.g., for JSON Lines.
/// enabled implicitly via the output format, e.g., for JSON Lines.
fn stats(&self) -> bool {
self.output_kind() == OutputKind::JSON || self.is_present("stats")
}

View File

@ -367,7 +367,7 @@ impl Glob {
}
}
/// This is like `ext`, but returns an extension even if it isn't sufficent
/// This is like `ext`, but returns an extension even if it isn't sufficient
/// to imply a match. Namely, if an extension is returned, then it is
/// necessary but not sufficient for a match.
fn required_ext(&self) -> Option<String> {

View File

@ -352,7 +352,7 @@ impl GlobSet {
/// Adds the sequence number of every glob pattern that matches the given
/// path to the vec given.
///
/// `into` is is cleared before matching begins, and contains the set of
/// `into` is cleared before matching begins, and contains the set of
/// sequence numbers (in ascending order) after matching ends. If no globs
/// were matched, then `into` will be empty.
pub fn matches_into<P: AsRef<Path>>(
@ -366,7 +366,7 @@ impl GlobSet {
/// Adds the sequence number of every glob pattern that matches the given
/// path to the vec given.
///
/// `into` is is cleared before matching begins, and contains the set of
/// `into` is cleared before matching begins, and contains the set of
/// sequence numbers (in ascending order) after matching ends. If no globs
/// were matched, then `into` will be empty.
///

View File

@ -134,7 +134,7 @@ impl<'a> Glob<'a> {
Glob(GlobInner::UnmatchedIgnore)
}
/// Return the file type defintion that matched, if one exists. A file type
/// Return the file type definition that matched, if one exists. A file type
/// definition always exists when a specific definition matches a file
/// path.
pub fn file_type_def(&self) -> Option<&FileTypeDef> {

View File

@ -59,7 +59,7 @@ pub fn interpolate<A, N>(
/// `CaptureRef` represents a reference to a capture group inside some text.
/// The reference is either a capture group name or a number.
///
/// It is also tagged with the position in the text immediately proceding the
/// It is also tagged with the position in the text immediately proceeding the
/// capture reference.
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
struct CaptureRef<'a> {

View File

@ -116,7 +116,7 @@ impl LiteralSets {
} else if lit.is_empty() {
// If we're here, then we have no LCP. No LCS. And no detected
// inner required literals. In theory this shouldn't happen, but
// the inner literal detector isn't as nice as we hope and doens't
// the inner literal detector isn't as nice as we hope and doesn't
// actually support returning a set of alternating required
// literals. (Instead, it only returns a set where EVERY literal
// in it is required. It cannot currently express "either P or Q

View File

@ -253,7 +253,7 @@ impl RegexMatcherBuilder {
/// they should impose a limit on the length, in bytes, of the concrete
/// pattern string. In particular, this is viable since this parser
/// implementation will limit itself to heap space proportional to the
/// lenth of the pattern string.
/// length of the pattern string.
///
/// Note that a nest limit of `0` will return a nest limit error for most
/// patterns but not all. For example, a nest limit of `0` permits `a` but