Tag: regex
All the articles with the tag "regex".
-
Regex to find the end of file (EOF) in Visual Studio Code
The regex $(?!\n) matches the true end of file in Visual Studio Code's multiline search mode, enabling EOF-only bulk replacements.
-
Escaping Invalid XML Unicode characters
Step-by-step derivation of a C# regex to strip or escape characters invalid in XML, handling UTF-16 surrogate pairs correctly.
-
Stripping invalid characters from UTF-16 strings
C# regex approach to remove unpaired UTF-16 surrogate characters from strings to ensure valid Unicode output.
-
Parse git merge commit messages
PowerShell function with regex patterns to parse git's auto-generated merge commit messages and extract branch names.