Skip to content

Commit

Permalink
Improve warning messages on invalid CODEOWNERS paths. (#5325)
Browse files Browse the repository at this point in the history
  • Loading branch information
Konrad Jamrozik authored Feb 3, 2023
1 parent 4e4970c commit 4149e70
Showing 1 changed file with 7 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,8 @@ private static bool ContainsUnsupportedSequences(string codeownersPath)
{
Console.Error.WriteLine(
$"CODEOWNERS path \"{codeownersPath}\" ends with " +
"unsupported sequence of \"/**\". Replace it with \"/\".");
"unsupported sequence of \"/**\". Replace it with \"/\". " +
"Until then this path will never match.");
return true;
}

Expand All @@ -173,7 +174,8 @@ private static bool ContainsUnsupportedSequences(string codeownersPath)
{
Console.Error.WriteLine(
$"CODEOWNERS path \"{codeownersPath}\" ends with " +
"unsupported sequence of \"/**/\". Replace it with \"/**\".");
"unsupported sequence of \"/**/\". Replace it with \"/\". " +
"Until then this path will never match.");
return true;
}

Expand All @@ -184,8 +186,9 @@ private static bool ContainsUnsupportedSequences(string codeownersPath)
{
Console.Error.WriteLine(
$"CODEOWNERS path \"{codeownersPath}\" contains " +
"unsupported sequence of \"**\" that is not \"/**/\". Replace it with \"*\". " +
"Until then this path will never match.");
"unsupported sequence of \"**\". Double star can be used only within slashes \"/**/\" " +
"or as a top-level catch all path of \"/**\". " +
"Currently this path will never match.");
return true;
}

Expand Down

0 comments on commit 4149e70

Please sign in to comment.