Starting to become a pretty big fan of regex. Want to validate a string and not use an absurd amount of code?
Starting to become a pretty big fan of regex. Want to validate a string and not use an absurd amount of code?
The NGINX map directive is one of the most powerful yet underutilized features in NGINX configuration. It allows you to create variables whose values depend on the values of other variables, enabling complex conditional logic without the performance penalty of multiple if statements. This guide covers everything you need to know about the NGINX map directive, from basic syntax to advanced…
URL rewriting is one of the most powerful features of NGINX, yet it remains one of the most misunderstood. If you have ever struggled with NGINX rewrite rules, copied configurations from Stack Overflow without understanding them, or wondered why your URL redirects are not working as expected, this guide is for you.
In this comprehensive guide, you will learn everything about NGINX URL rewriting:…
Understanding how NGINX routes requests to different location blocks is essential for anyone configuring web servers. The location directive is one of the most powerful yet frequently misunderstood features in NGINX configuration. Getting NGINX location priority wrong can break your application, create security vulnerabilities, or cause subtle bugs that are difficult to diagnose.
This…
Thank you! :D I love RegEx as well, write it for fun actually xD
If anyone needs a RegEx written, send me the requested specifications and I’ll write it for you :3
used a complex regex for io/string manipulation. you wish you were as powerful as i
when you write a really long spreadsheet formula and/or regular expression that solves all your problems 🥴🥴🥴
Regular Expressions, commonly known as Regex, are a powerful feature in JavaScript that allow developers to search, match, and manipulate strings efficiently. Whether you’re validating email addresses, phone numbers, or cleaning up user input, understanding Regex can save a lot of time and make your code more robust.
In this blog post, we’ll break down Regex in JavaScript, explain key concepts, share useful tips, and provide practical examples for beginners and intermediate developers.
A regular expression is a sequence of characters that defines a search pattern. Think of it as a way for JavaScript to identify specific text patterns in strings. Regex is widely used for validation, search, replace operations, and string manipulation.
In JavaScript, Regex can be used in two ways:
let pattern = /hello/;
let pattern = new RegExp(“hello”);
Both methods create a Regex object that can be used with JavaScript string methods like .test(), .match(), .replace(), and .search().
Checks if a pattern exists in a string and returns true or false.let pattern = /world/; console.log(pattern.test(“Hello world”)); // true
Returns an array of matches found in the string.let text = “I love JavaScript”; let matches = text.match(/JavaScript/); console.log(matches[0]); // “JavaScript”
Replaces matched patterns in a string with a new value.let text = “I love cats”; let newText = text.replace(/cats/, “dogs”); console.log(newText); // “I love dogs”
Returns the index of the first match or -1 if not found.let text = “Learn JavaScript”; console.log(text.search(/JavaScript/)); // 6
Here are some common patterns used in JavaScript Regex: Pattern Description Example . Matches any single character /a.b/ matches “acb” ^ Start of string /^Hello/ matches “Hello World” $ End of string /World$/ matches “Hello World” \d Matches any digit [0-9]/\d/ matches “7” \D Non-digit /\D/ matches “a” \w Word character [a-zA-Z0-9_]/\w/ matches “A” \W Non-word character /\W/ matches “!” \s Whitespace /\s/ matches “ ” \S Non-whitespace /\S/ matches “a” + One or more occurrences /a+/ matches “aa” * Zero or more occurrences /a*/ matches “aaa” ? Zero or one occurrence /a?/ matches “a” or “” [abc] Matches any character a, b, or c /[abc]/ matches “a” [^abc] Matches anything except a, b, c /[^abc]/ matches “d”
let emailPattern = /^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+.[a-z]{2,}$/; console.log(emailPattern.test(“example@gmail.com”)); // true
let phonePattern = /^\d{10}$/; console.log(phonePattern.test(“9876543210”)); // true
let text = “JavaScript is awesome”; let cleanedText = text.replace(/\s+/g, “ ”); console.log(cleanedText); // “JavaScript is awesome”
let str = “There are 15 apples and 20 oranges”; let numbers = str.match(/\d+/g); console.log(numbers); // [“15”, “20”]
let pattern = /javascript/i; console.log(pattern.test(“I love JavaScript”)); // true
let text = “apple banana apple”; let matches = text.match(/apple/g); console.log(matches); // [“apple”, “apple”]
let pattern = /./; // matches a dot
Regex is extremely useful when you want to:
However, avoid overusing Regex for very complex operations as it can become hard to read and maintain.
JavaScript Regular Expressions are a powerful tool that every developer should learn. From validating forms to extracting data from strings, Regex makes string manipulation efficient and flexible.
By understanding basic patterns, flags, and methods like .test(), .match(), and .replace(), beginners can handle most real-world scenarios. Remember to practice with examples, use online regex testers, and gradually explore advanced patterns.

Ah yes. The circle of hell nobody ever talks about.
Regular Expressions
A few Unknown Event Playtest Cards can be see here.
The Snapstone Wielder: -t:land
The Traveling Postman: o:/create/ -o:/that’s a copy/
fast-escape-regexp is a high-performance JavaScript utility that escapes special characters in a string for safe use in regular expressions.
This TypeScript-written library delivers 2-3x faster performance compared to existing solutions while maintaining compatibility across all JavaScript runtimes, including browsers and Node.js.
Key Features:
Performance optimization: Delivers 2-3x faster…
High-Performance JavaScript RegExp Escaping with Fast-Escape-Regexp
Hot take: Regex is an esoteric language.
es·o·ter·ic
/ˌesəˈterik/
Intended for or likely to be understood by only a small number of people with a specialized knowledge or interest.
And yes, regular expressions are programs! (literally)

Mine, but of course!
When I joined Tumblr, I was only expecting to save the pr0n and cat pics that I liked. I didn’t want others to link it with my normal online personality.
Then I found @dailyrothko , whose posts make me ecstatic each time. I wound up going to the Rothko compendium in Paris last year because I wanted to compare colors.
Recently I have subscribed to a lot of trans blogs that pretend to be Linux distros. These have been very eye-opening but also comforting. I’m too old and too comfy with my Johnson bar to come out of an egg. Nevertheless, I am glad to hear the minds of people that could have helped me three decades ago.
Oh, and I am not the hidden account of someone famous.
Thank you very much for your question!
“Regex is a pattern-matching language; it’s a way to expressively describe patterns that match strings (e.g., words or sentences). For example, say you’re searching your hard drive for an image called foo, but you cannot remember if it’s a JPEG or a PNG. Many utilities make use of regex for searching, transforming, and interacting with text.”
You won’t be able to just effortlessly compose your own regex after just reading the linked article, but a quick read through will at least help put it in context. It also gives a feel of what regex can be used for. The reason regex persists after many years, despite looking very confusing, is that it is very powerful. With many GUI applications, you could well find regex running in the background to perform the more complex tasks.
See https://www.howtogeek.com/get-started-with-regex-in-linux-terminal
Mastering the grep Command in Linux
Unlock the full power of grep in Linux with this comprehensive tutorial! Whether you’re a beginner or an advanced user, learn how to effectively search, filter, and manipulate text files and logs using the powerful grep command. Mastering this tool will save you time and boost your productivity.
In this video, we cover everything from basic usage to advanced techniques including regular expressions, recursive search, and context filtering. By the end of this video, you’ll be using grep like a pro, making it an essential tool in your Linux toolkit.
Setting up the environment for grep – Learn how to set up directories and files for testing common use cases like log analysis.
Basic grep usage – Search for exact string matches with options like -i (case-insensitive) and -n (line numbers).
Recursive search – Use grep to search through all files and subdirectories with the -r flag.
Regular Expressions – Discover how to search for complex patterns using grep’s extended regex capabilities.
Showing context – Learn how to display lines before (-B), after (-A), and around matches (-C) to give more context to your searches.
Advanced grep options – Count matches (-c), invert matches (-v), match whole words (-w), and more.
Color-coded output – Enable colored output for better visibility of matches.
Using grep with pipes and output redirection – Combine grep with other commands and redirect output to files.
grep "pattern" filename
grep -r "pattern" .
grep -E "Error|Warning"
grep -B 1 "Warning"
grep -C 1 "Error"
grep --color=always "pattern"
grep "pattern" file > output.txt

In diesem Beitrag möchte ich dir zeigen, wie du mit regulären Ausdrücken Text auf dem Arduino prüfen kannst.
Mit regulären Ausdrücken kannst du Text auf eine bestimmte Syntax oder das Vorhandensein von Daten prüfen. Hierzu zählt zbsp. das Prüfen auf den korrekten Aufbau einer E-Mail, Telefonnummer etc. Man kann aber auch prüfen oder zählen, wie oft eine Zeichenkette in einem Text vorkommt.
Die regulären Ausdrücke sind manchmal sehr kompliziert und lassen sich auch ebenso gerade für Anfänger schwer lesen, hier hilft ein online-Tool wie https://regex101.com/ weiter, welcher dir beim Aufbau und Texten hilft.
Die Arduino IDE liefert per Default keine Funktionalität zum Ausführen von regulären Ausdrücken, hier müssen wir uns einer externen Bibliothek behelfen, welche wir über den Bibliotheksmanager installieren.
Der Entwickler hat im einen extra Forumeintrag unter https://forum.arduino.cc/t/new-regular-expression-library-released/59770 verfasst und dort die Funktionalität dieser Bibliothek beschrieben.
Achtung: Dieser Beitrag kann nicht alle RegEx behandeln, dafür gibt es einfach zu viele. Ich möchte mich hier auf einige wenige beschränken.

heartbreaking: girl writes [a-z1-9] in her regex instead of [a-z0-9], spends half an hour debugging the program that mysteriously broke at the 10th element