You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Update whitelist includes
* Lock whitelist entries to a specific version
* Rebase to get checkstyle update and fix a grammar issue
* rebase to get pom restructure changes
Write-Error-With-Color "Error: Missing plugin version update tag for groupId=$($groupId), artifactId=$($artifactId). The tag should be <!-- {x-version-update;$($groupId):$($artifactId);current|dependency|external_dependency<select one>} -->"
494
499
}
495
-
}
500
+
}
501
+
502
+
# This is for the whitelist dependencies. Fetch the banned dependencies
# The groupId match has to be able to deal with <area>_ for external dependency exceptions
517
+
if (!$includeNode.NextSibling-or$includeNode.NextSibling.NodeType-ne"Comment")
518
+
{
519
+
$script:FoundError=$true
520
+
Write-Error-With-Color "Error: <include> is missing the update tag which should be <!-- {x-include-update;$($groupId):$($artifactId);external_dependency} -->"
Write-Error-With-Color "Error: <include> version update tag for $($includeNode.InnerText) should be <!-- {x-include-update;$($groupId):$($artifactId);external_dependency} -->"
526
+
}
527
+
else
528
+
{
529
+
# verify that the version is formatted correctly
530
+
if (!$version.StartsWith("[") -or!$version.EndsWith("]"))
531
+
{
532
+
$script:FoundError=$true
533
+
Write-Error-With-Color "Error: the version entry '$($version)' for <include> '$($rawIncludeText)' is not formatted correctly. The include version needs to of the form '[<version>]', the braces lock the include to a specific version for these entries. -->"
if ($versionWithoutBraces-ne$extDepHash[$depKey].ver)
546
+
{
547
+
$script:FoundError=$true
548
+
Write-Error-With-Color "Error: $($depKey)'s version is '$($versionWithoutBraces)' but the external_dependency version is listed as $($extDepHash[$depKey].ver)"
549
+
}
550
+
}
551
+
else
552
+
{
553
+
$script:FoundError=$true
554
+
Write-Error-With-Color "Error: the groupId:artifactId entry '$($depKey)' for <include> '$($rawIncludeText)' is not a valid external dependency. Please verify the entry exists in the external_dependencies.txt file. -->"
555
+
}
556
+
}
557
+
}
558
+
}
559
+
# The only time a split count of 2 is allowed is in the following case.
560
+
# <include>com.azure:*</include>
561
+
# These entries will not and should not have an update tag
562
+
elseif ($split.Count-eq2)
563
+
{
564
+
if ($rawIncludeText-ne$ComAzureWhitelistInclude)
565
+
{
566
+
$script:FoundError=$true
567
+
Write-Error-With-Color "Error: $($rawIncludeText) is not a valid <include> entry. With the exception of the $($ComAzureWhitelistInclude), every <include> entry must be of the form <include>groupId:artifactId:[version]<include>"
568
+
}
569
+
}
570
+
else
571
+
{
572
+
# At this point the include entry is wildly incorrect.
573
+
$script:FoundError=$true
574
+
Write-Error-With-Color "Error: $($rawIncludeText) is not a valid <include> entry. Every <include> entry must be of the form <include>groupId:artifactId:[version]<include>"
0 commit comments