7 0
Sign in to rate

RegEx – ultimate deck

0.03MB. 0 audio & 0 images. Updated 2020-01-24.
The author has shared 11 other item(s).

Description

All regular expressions (RegEx) of a PCRE (PHP) flavor, taken from the "quick reference" of regex101.com (online regex tester and debugger). The deck is well divided into appropriate subdecks: Each note is appropriately formatted to ease the readability. Additionally, every note is supported by an example. Finally, the most common tokens are marked by a "commontoken" tag. ------------------------------------------------------- >More decks by pyXelr<

Sample (from 143 notes)

Cards are customizable! When this deck is imported into the desktop program, cards will appear as the deck author has made them. If you'd like to customize what appears on the front and back of a card, you can do so by clicking the Edit button, and then clicking the Cards button.
Front Vertical whitespace character
Syntax (back) \v
Description (back) Matches newlines and vertical tabs. Works with Unicode. Vertical tabs can be inserted in some word processors using CMD/CTRL+ENTER.
Example code (back) /(\v)/
Example matching (back) line one line two
Tags metasequence regex
Front Regex engine modifier = NO_START_OPT
Syntax (back) (*NO_START_OPT)
Description (back) Before even attempting a match, the regex engine makes some checks, such as the length of the string. If it is not long enough to fit the pattern, it will automatically return a no match. This optimization can be disabled by using this modifier.
Example code (back)
Example matching (back)
Tags groupconstruct regex regexenginemodifier
Front Regex engine modifier = NO_AUTO_POSSESS
Syntax (back) (*NO_AUTO_POSSESS)
Description (back) The PCRE regex engine automatically applies some internal optimizations to regexes to avoid unnecessary backtracking. This modifier will disable that behavior, and thus the engine will backtrack until the previously matching instruction fails to do so.
Example code (back)
Example matching (back)
Tags groupconstruct regex regexenginemodifier

After the file is downloaded, double-click on it to open it in the desktop program.

At this time, it is not possible to add shared decks directly to your AnkiWeb account - they need to be added from the desktop then synchronized to AnkiWeb.

Reviews

on 1637247431
Really helpful! I wouldn't have approached RegEx without this.
on 1633489096
Thanks
on 1618872337
Absolutely terrific. Comprehensive and well explained with detailed examples.
on 1595873328
This deck is very well put together, and super helpful for learning regex!
Comment from author
Great, I'm happy to hear that!
on 1589947017
Pretty thorough deck!
on 1579098076
Saved me the time of making my own cards! Nicely sorted into tags so that I can choose which cards I want.
on 1578033234
This is a really well-made deck not only because it is so comprehensive, but even more so because it comes with examples and explanations. These make learning much easier and faster. I only need the basics, which are easy to identify because they are tagged: commontoken.