[Feature] Regex Rules - #172

Closed
opened 2026-02-28 18:51:01 -06:00 by GiteaMirror · 6 comments
Owner

Originally created by @rich-howell on GitHub (Jan 22, 2023).

Discussed in https://github.com/actualbudget/actual/discussions/395

Originally posted by snovak December 1, 2022
I think it would be very powerful to introduce Regex matching, or some simple pattern matching, for Rules.

Here is a mockup of what the UI might look like. The two bottom rules should achieve the same result with far less configuration.
RuleMatches

Originally created by @rich-howell on GitHub (Jan 22, 2023). ### Discussed in https://github.com/actualbudget/actual/discussions/395 <div type='discussions-op-text'> <sup>Originally posted by **snovak** December 1, 2022</sup> I think it would be very powerful to introduce Regex matching, or some simple pattern matching, for Rules. Here is a mockup of what the UI might look like. The two bottom rules should achieve the same result with far less configuration. ![RuleMatches](https://user-images.githubusercontent.com/317561/205163741-364535f6-ae70-4621-b25a-92e398eb62ea.png) </div>
GiteaMirror added the rulesneeds votesfeaturehelp wanted labels 2026-02-28 18:51:01 -06:00
Author
Owner

@Bryce-MW commented on GitHub (Mar 15, 2023):

Additionally, it would be very useful to be able to use captures from the regex in the actions. I have quite a few rules checking for notes is DEPOSIT;XYZ;Electronic Funds Transfer -> set payee to XYZ because my bank doesn't always set the payee. Though of course this would be more difficult to implement. I can take a look at some point but I don't exactly use JS often.

@Bryce-MW commented on GitHub (Mar 15, 2023): Additionally, it would be very useful to be able to use captures from the regex in the actions. I have quite a few rules checking for `notes is DEPOSIT;XYZ;Electronic Funds Transfer -> set payee to XYZ` because my bank doesn't always set the payee. Though of course this would be more difficult to implement. I can take a look at some point but I don't exactly use JS often.
Author
Owner

@github-actions[bot] commented on GitHub (May 1, 2023):

Thanks for sharing your idea!

This repository is now using lodash style issue management for enhancements. This means enhancement issues will now be closed instead of leaving them open. This doesn’t mean we don’t accept feature requests, though! We will consider implementing ones that receive many upvotes, and we welcome contributions for any feature requests marked as needing votes (just post a comment first so we can help you make a successful contribution).

The enhancement backlog can be found here: https://github.com/actualbudget/actual/issues?q=label%3A%22needs+votes%22+sort%3Areactions-%2B1-desc+

Don’t forget to upvote the top comment with 👍!

@github-actions[bot] commented on GitHub (May 1, 2023): :sparkles: Thanks for sharing your idea! :sparkles: This repository is now using lodash style issue management for enhancements. This means enhancement issues will now be closed instead of leaving them open. This doesn’t mean we don’t accept feature requests, though! We will consider implementing ones that receive many upvotes, and we welcome contributions for any feature requests marked as needing votes (just post a comment first so we can help you make a successful contribution). The enhancement backlog can be found here: https://github.com/actualbudget/actual/issues?q=label%3A%22needs+votes%22+sort%3Areactions-%2B1-desc+ Don’t forget to upvote the top comment with 👍!
Author
Owner

@quangkieu commented on GitHub (Apr 30, 2024):

From reading the code, Actual "contains" rules is already sql "like" function, which use "_" for single char wildcard, % for multiple character wildcard. I do not see any escape character so right now you would not able to search for literly % or _

@quangkieu commented on GitHub (Apr 30, 2024): From reading the code, Actual "contains" rules is already sql "like" function, which use "_" for single char wildcard, % for multiple character wildcard. I do not see any escape character so right now you would not able to search for literly % or _
Author
Owner

@esseti commented on GitHub (Jul 9, 2024):

Will this also be able to do a rule to remove, or partially remove, a string from notes or allow to use the groups in the output?
such as:

Payment via ATM DATE-TIME OP. 02-07-2024 12.17.00 GAMESTOP" -> "[02-07-2024 12.17.00] GAMESTOP"

@esseti commented on GitHub (Jul 9, 2024): Will this also be able to do a rule to remove, or partially remove, a string from notes or allow to use the groups in the output? such as: `Payment via ATM DATE-TIME OP. 02-07-2024 12.17.00 GAMESTOP"` -> `"[02-07-2024 12.17.00] GAMESTOP"`
Author
Owner

@CrazyKidJack commented on GitHub (Sep 13, 2024):

I think the regex part of this has already been implemented for "Imported Payee" and "Notes".
It'd still ben ice to have it in the other fields.

And +💯 for the regex captures and backreferences idea

@CrazyKidJack commented on GitHub (Sep 13, 2024): I think the regex part of this has already been implemented for "Imported Payee" and "Notes". It'd still ben ice to have it in the other fields. And +💯 for the regex captures and backreferences idea
Author
Owner

@DenizUgur commented on GitHub (Sep 24, 2024):

Not sure if it's related to this feature as well but having the ability to use RegEx match groups would be fantastic. For example, I have intra-account transfers marked with a 4-digit transfer code on the payee, and receiving transactions makes that available in the notes. So matching those numbers via regex would be a godsend.

@DenizUgur commented on GitHub (Sep 24, 2024): Not sure if it's related to this feature as well but having the ability to use RegEx match groups would be fantastic. For example, I have intra-account transfers marked with a 4-digit transfer code on the payee, and receiving transactions makes that available in the notes. So matching those numbers via regex would be a godsend.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#172