All Projects → tylerbarker → Verbalex

tylerbarker / Verbalex

Licence: apache-2.0
A library for creating complex, composable regular expressions with the reader & writer in mind. 🔍

Programming Languages

elixir
2628 projects

Projects that are alternatives of or similar to Verbalex

expressive-ts
A functional programming library designed to simplify building complex regular expressions
Stars: ✭ 78 (+200%)
Mutual labels:  regex, regular-expressions
lc-data-intro
Library Carpentry: Introduction to Working with Data (Regular Expressions)
Stars: ✭ 16 (-38.46%)
Mutual labels:  regex, regular-expressions
tokenquery
TokenQuery (regular expressions over tokens)
Stars: ✭ 28 (+7.69%)
Mutual labels:  regex, regular-expressions
Ruby Regexp
Learn Ruby Regexp step by step from beginner to advanced levels with plenty of examples and exercises
Stars: ✭ 79 (+203.85%)
Mutual labels:  regex, regular-expressions
Re Flex
The regex-centric, fast lexical analyzer generator for C++ with full Unicode support. Faster than Flex. Accepts Flex specifications. Generates reusable source code that is easy to understand. Introduces indent/dedent anchors, lazy quantifiers, functions for lex/syntax error reporting, and more. Seamlessly integrates with Bison and other parsers.
Stars: ✭ 274 (+953.85%)
Mutual labels:  regex, regular-expressions
url-regex-safe
Regular expression matching for URL's. Maintained, safe, and browser-friendly version of url-regex. Resolves CVE-2020-7661 for Node.js servers.
Stars: ✭ 59 (+126.92%)
Mutual labels:  regex, regular-expressions
unmatcher
Regular expressions reverser for Python
Stars: ✭ 26 (+0%)
Mutual labels:  regex, regular-expressions
Regex For Regular Folk
🔍💪 Regular Expressions for Regular Folk — A visual, example-based introduction to RegEx [BETA]
Stars: ✭ 242 (+830.77%)
Mutual labels:  regex, regular-expressions
Pawn.Regex
🔎 Plugin that adds support for regular expressions in Pawn
Stars: ✭ 34 (+30.77%)
Mutual labels:  regex, regular-expressions
crystular
Crystal regex tester http://www.crystular.org/
Stars: ✭ 31 (+19.23%)
Mutual labels:  regex, regular-expressions
ChatControl-Pro
The ultimate chat solution. Prevent spam, ads, swears and even bots on your server. Replaced by ChatControl Red: https://mineacademy.org/chatcontrol-red
Stars: ✭ 65 (+150%)
Mutual labels:  regex, regular-expressions
Social Media Profiles Regexs
📇 Extract social media profiles and more with regular expressions
Stars: ✭ 324 (+1146.15%)
Mutual labels:  regex, regular-expressions
moar
Deterministic Regular Expressions with Backreferences
Stars: ✭ 19 (-26.92%)
Mutual labels:  regex, regular-expressions
simplematch
Minimal, super readable string pattern matching for python.
Stars: ✭ 147 (+465.38%)
Mutual labels:  regex, regular-expressions
Rverbalexpressions
💬 Create regular expressions easily
Stars: ✭ 245 (+842.31%)
Mutual labels:  regex, regular-expressions
python-hyperscan
A CPython extension for the Hyperscan regular expression matching library.
Stars: ✭ 112 (+330.77%)
Mutual labels:  regex, regular-expressions
Grex
A command-line tool and library for generating regular expressions from user-provided test cases
Stars: ✭ 4,847 (+18542.31%)
Mutual labels:  regex, regular-expressions
Fancy Regex
Rust library for regular expressions using "fancy" features like look-around and backreferences
Stars: ✭ 199 (+665.38%)
Mutual labels:  regex, regular-expressions
RgxGen
Regex: generate matching and non matching strings based on regex pattern.
Stars: ✭ 45 (+73.08%)
Mutual labels:  regex, regular-expressions
Regex
The Hoa\Regex library.
Stars: ✭ 308 (+1084.62%)
Mutual labels:  regex, regular-expressions

Verbalex

Hex pm

Verbalex is a library for creating complex regular expressions with the reader & writer in mind. It does not aim to replace Elixir's already excellent Regex module for operating on regex. Instead, it focuses only on building the ~r/regexes/ themselves.

alias Verbalex, as: Vlx

protocols = ""
  |> Vlx.find("http")
  |> Vlx.maybe("s")
  |> Vlx.then("://")
  |> Vlx.capture_as("protocols")
  |> Regex.compile!()

# ~r/(?<protocols>(?:http)s?(?::\/\/))/

Regex.named_captures(protocols, "https://github.com/tylerbarker")
# %{"protocols" => "https://"}

Installation

def deps do
  [
    {:verbalex, "~> 0.3.0"}
  ]
end

Docs

Documentation can be found at https://hexdocs.pm/verbalex.

Acknowledgements

Verbalex is essentially an Elixir port of the popular Verbal Expressions family of libraries, while also taking some inspiration from Simple Regex.

Thanks to Max Szengal for laying down the groundwork in 2013 with ElixirVerbalExpressions.

Contributing

For issues, comments or feedback please first create an issue.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].