Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Add pcre2 ripgrep option #1095

Merged
merged 1 commit into from
Jul 3, 2019
Merged

Add pcre2 ripgrep option #1095

merged 1 commit into from
Jul 3, 2019

Conversation

dwelle
Copy link
Contributor

@dwelle dwelle commented Jun 30, 2019

Description of the Change

Added option to enable pcre2 ripgrep regex engine, as discussed in here.

NOTE: I haven't written any specs because I'm not sure what steps to take. Should I wrap all the specs in additional loop, same as prev PR has done with ripgrep support?

NOTE: cannot build Atom ATM so haven't tested the changes locally.

Benefits

Allows additional regex features such as lookbehind.

Possible Drawbacks

Enabling PCRE2 potentially incurs performance penalty, as explained on ripgrep's wiki, thus this PR does not enable it by default, and instead adds an option.

Applicable Issues

Addresses #571

Accompanying PR in atom core

Copy link
Contributor

@rafeca rafeca left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I've done some basic testing and this PR seems to be working fine. Once the PR on atom/atom gets merged we can ship this one.

@dwelle
Copy link
Contributor Author

dwelle commented Jul 3, 2019

Just reminding that this can now be merged, too.

@rafeca
Copy link
Contributor

rafeca commented Jul 3, 2019

Thanks for the reminder 😃

@rafeca rafeca merged commit 9757429 into atom:master Jul 3, 2019
@dwelle
Copy link
Contributor Author

dwelle commented Jul 13, 2019

Mhm, seems it didn't work. I have both ripgrep and PCRE2 option enabled, but the parser complains the regex is invalid. Is that coming from ripgrep or atom? How come specs passed?

image

EDIT: hold on a minute. I've updated find-and-replace, but haven't updated core (still on stable). That must be it. So actually we should have waited with merging this PR, after all :)

@Arcanemagus
Copy link

The update of find-and-replace hasn't hit the beta channel yet, you can test it out on the nightly releases now, or wait for it to hit beta/stable during the normal release cycle.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants