Last active
May 3, 2019 18:05
-
-
Save MathieuAuclair/5298cc04f349bcef353c043097250846 to your computer and use it in GitHub Desktop.
Set of regex to catch @tag in a text
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
RegexDictionary = new Dictionary<string, Regex> | |
{ | |
{"tests", new Regex("@tests\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"fixed", new Regex("@fixed\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"review", new Regex("@review\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"tested", new Regex("@tested\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"submitassistant", new Regex("@submitassistant\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"releasenotes", new Regex("@releasenotes\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"change", new Regex("@change\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"waswarned", new Regex("@waswarned\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
{"inprogress", new Regex("@inprogress\\((.*?)\\)(.*?)@.*?\\(.*?\\)", option)}, | |
}; | |
// This regex will catch the content in a @tag or after the at tag | |
/// EXEMPLE - trying to get the content in @fixed tag | |
// | |
// @fixed(<this content will be catched>) <This content will too!> @ <this too> @othertag(<not catched>) <not cached!> | |
// |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment