Can anyone please recommend a good plugin to replace built-in vim regex search with PCRE regex?

This page summarizes the projects mentioned and recommended in the original post on /r/vim

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • eregex.vim

    Perl/Ruby style regexp notation for Vim

  • I think eregex.vim was the plugin I last saw that did this, but I haven't tried it. I don't like putting too much between me and /. I use /\v when I want something closer to PCRE.

  • vim-grepper

    :space_invader: Helps you win at grep.

  • This wouldn’t be a direct replacement for searching, but could you create/find a tool which uses perl regex to fill the location window? e.g you can use vim-grepper and modify the rg command with --pcre to use the pcre2 engine.

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

    WorkOS logo
  • RE2

    RE2 is a fast, safe, thread-friendly alternative to backtracking regular expression engines like those used in PCRE, Perl, and Python. It is a C++ library.

  • In case it matters, PCRE is not 100% compatible with Perl regular expression syntax, and both have differences from Perl-inspired regexes in various programming languages. This table lists some differences between engines, though it omits Vim's syntax. The RE2 syntax page has details on Perl, PCRE, and Vim syntax as they differ from RE2.

  • ripgrep

    ripgrep recursively searches directories for a regex pattern while respecting your gitignore

  • I’m no expert, but I believe ripgrep will do PCRE, and there are more than a couple vim plugins that’ll leverage it. I happen to use vim-ripgrep, which is good enough for me, but not sure if it’ll let you get at the PCRE option (I’d guess it should, but I haven’t checked).

  • vim-ripgrep

    Use RipGrep in Vim and display results in a quickfix list

  • I’m no expert, but I believe ripgrep will do PCRE, and there are more than a couple vim plugins that’ll leverage it. I happen to use vim-ripgrep, which is good enough for me, but not sure if it’ll let you get at the PCRE option (I’d guess it should, but I haven’t checked).

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts