Ripgrep 13.0

Last modified on June 17, 2021

ripgrep 13 is a model up to date indispensable model unlock of ripgrep that primarily contains
bug fixes, some efficiency enhancements and a few minor breaking modifications.
There may per likelihood be moreover a repair for a safety vulnerability on Windows
(CVE-2021-3013).

Whenever you haven't heard of it before, ripgrep is a line-oriented search
instrument that recursively searches the current listing for a regex pattern. By
default, ripgrep will respect gitignore rules and robotically skip hidden
information/directories and binary information.

Some highlights:

A model up to date transient flag, -., has been added. It is an alias for the --hidden flag,
which instructs ripgrep to look hidden information and directories.

ripgrep is now the utilization of a model up to date
vectorized implementation of memmem,
which quickens many frequent searches. For those that discover any efficiency
regressions (or indispensable enhancements), I may per likelihood look after to take heed to about them through an
instruct characterize!

Also, for Windows clients focused on MSVC, Cargo will now make absolutely static
executables of ripgrep. The unlock binaries for ripgrep 13 had been compiled
the utilization of this configuration.

BREAKING CHANGES:

Binary detection output has modified barely.

In this unlock, a puny tweak has been made to the output format when a binary
file is detected. Previously, it regarded love this:

Binary file FOO fits (came upon " " byte spherical offset XXX)

Now it seems to be like love this:

FOO: binary file fits (came upon " " byte spherical offset XXX)

vimgrep output in multi-line now handiest prints the primary line for every match.

Judge instruct 1866 for extra
dialogue on this. Previously, every line in a match grew to become as quickly as duplicated, even
when it spanned multiple traces. There are not any modifications to vimgrep output when
multi-line mode is disabled.

In multi-line mode, --depend is now the identical to --depend-suits.

This seems to match how pcre2grep implements --depend. Previously, ripgrep
would invent outright flawed counts. Any different fairly numerous may per likelihood per likelihood be to merely
rely the choice of lines---although or not it's greater than the choice of suits---but
that appears extremely unintuitive.

FULL LIST OF FIXES AND IMPROVEMENTS:

Security fixes:

  • CVE-2021-3013:
    Fixes a safety hole on Windows the assign working ripgrep with both the
    -z/--search-zip or --pre flags may per likelihood per likelihood additionally consequence in working arbitrary
    executables from the current listing.
  • VULN #1773:
    Here is most people going through instruct monitoring CVE-2021-3013. ripgrep's README
    now contains a portion describing recommendations on find out how to characterize a vulnerability.

Performance enhancements:

  • PERF #1657:
    Take a take a look at if a file have to be unnoticed first before issuing stat calls.
  • PERF memchr#82:
    ripgrep now makes declare of a model up to date vectorized implementation of memmem.

Goal enhancements:

  • Added or improved file kind filtering for ASP, Bazel, dvc, FlatBuffers,
    Futhark, minified information, Mint, pofiles (from GNU gettext) Racket, Red, Ruby,
    VCL, Yang.
  • FEATURE #1404:
    ripgrep now prints a warning if nothing is searched.
  • FEATURE #1613:
    Cargo will now invent static executables on Windows when the utilization of MSVC.
  • FEATURE #1680:
    Add -. as a transient flag alias for --hidden.
  • FEATURE #1842:
    Add --enviornment-{context,match}-separator for customizing enviornment delimiters.
  • FEATURE #1856:
    The README now hyperlinks to a
    Spanish translation.

Computer virus fixes:

  • BUG #1277:
    Doc cygwin route translation habits within the FAQ.
  • BUG #1739:
    Repair bug the assign replacements had been buggy if the regex matched a line terminator.
  • BUG #1311:
    Repair multi-line bug the assign a search & substitute for n did no longer work as anticipated.
  • BUG #1401:
    Repair buggy interplay between PCRE2 peep-round and -o/--handiest-matching.
  • BUG #1412:
    Repair multi-line bug with searches the utilization of peep-round previous matching traces.
  • BUG #1577:
    Fish shell completions will proceed to be auto-generated.
  • BUG #1642:
    Fixes a bug the assign the utilization of -m and -A printed extra fits than the restrict.
  • BUG #1703:
    Account for the characteristic of -u/--unrestricted.
  • BUG #1708:
    Account for a way -S/--handsome-case works.
  • BUG #1730:
    Account for that CLI invocation should all the time be reputable, no matter config file.
  • BUG #1741:
    Repair stdin detection when the utilization of PowerShell in UNIX environments.
  • BUG #1756:
    Repair bug the assign foo/ would match foo, however it should not.
  • BUG #1765:
    Repair awe when --crlf is former in some situations.
  • BUG #1638:
    Precisely sniff UTF-Eight and assemble transcoding, love we assemble for UTF-16.
  • BUG #1816:
    Add documentation for glob alternate syntax, e.g., {a,b,..}.
  • BUG #1847:
    Account for a way the --hidden flag works.
  • BUG #1866:
    Repair bug when computing column numbers in --vimgrep mode.
  • BUG #1868:
    Repair bug the assign --passthru and -A/-B/-C did no longer override every heaps of.
  • BUG #1869:
    Account for medical docs for --files-with-suits and --files-with out-match.
  • BUG #1878:
    Repair bug the assign A may per likelihood per likelihood invent unanchored fits in multiline search.
  • BUG 94e4b8e3:
    Repair column numbers with --vimgrep is former with -U/--multiline.

Read More

Similar Products:

Recent Content