Rename target, remove unused parameter, and add comments to the AnalyzeBuildGraph task
This commit is contained in:
parent
997be52987
commit
dc50526a6d
|
|
@ -106,7 +106,7 @@
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name="BuildRepositories"
|
<Target Name="BuildRepositories"
|
||||||
DependsOnTargets="_PrepareRepositories;_CreateRepositoriesListWithCommits;_UpdateNuGetConfig;Graph;_BuildRepositories" />
|
DependsOnTargets="_PrepareRepositories;_CreateRepositoriesListWithCommits;_UpdateNuGetConfig;ComputeGraph;_BuildRepositories" />
|
||||||
|
|
||||||
<Target Name="ResolveRepoInfo" DependsOnTargets="_PrepareRepositories">
|
<Target Name="ResolveRepoInfo" DependsOnTargets="_PrepareRepositories">
|
||||||
<MSBuild Projects="$(MSBuildProjectFullPath)"
|
<MSBuild Projects="$(MSBuildProjectFullPath)"
|
||||||
|
|
@ -149,7 +149,7 @@
|
||||||
<Error Text="No solutions were found in '$(_CloneRepositoryRoot)'" Condition="@(Solution->Count()) == 0" />
|
<Error Text="No solutions were found in '$(_CloneRepositoryRoot)'" Condition="@(Solution->Count()) == 0" />
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name="Graph" DependsOnTargets="ResolveRepoInfo">
|
<Target Name="ComputeGraph" DependsOnTargets="ResolveRepoInfo">
|
||||||
<RepoTasks.AnalyzeBuildGraph
|
<RepoTasks.AnalyzeBuildGraph
|
||||||
Solutions="@(Solution)"
|
Solutions="@(Solution)"
|
||||||
Artifacts="@(ArtifactInfo)"
|
Artifacts="@(ArtifactInfo)"
|
||||||
|
|
|
||||||
|
|
@ -38,8 +38,6 @@ namespace RepoTasks
|
||||||
[Required]
|
[Required]
|
||||||
public string Properties { get; set; }
|
public string Properties { get; set; }
|
||||||
|
|
||||||
public string StartGraphAt { get; set; }
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// The order in which to build repositories
|
/// The order in which to build repositories
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|
@ -105,7 +103,11 @@ namespace RepoTasks
|
||||||
foreach (var tfm in proj.Frameworks)
|
foreach (var tfm in proj.Frameworks)
|
||||||
foreach (var dependency in tfm.Dependencies)
|
foreach (var dependency in tfm.Dependencies)
|
||||||
{
|
{
|
||||||
if (!buildPackageMap.TryGetValue(dependency.Key, out var package)) continue;
|
if (!buildPackageMap.TryGetValue(dependency.Key, out var package))
|
||||||
|
{
|
||||||
|
// this dependency is not a PackageReference to something that we build in Universe
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
var refVersion = VersionRange.Parse(dependency.Value.Version);
|
var refVersion = VersionRange.Parse(dependency.Value.Version);
|
||||||
if (refVersion.IsFloating && refVersion.Float.Satisfies(package.PackageInfo.Version))
|
if (refVersion.IsFloating && refVersion.Float.Satisfies(package.PackageInfo.Version))
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ namespace RepoTasks
|
||||||
version = version.Substring(0, version.Length - BuildNumber.Length) + "*";
|
version = version.Substring(0, version.Length - BuildNumber.Length) + "*";
|
||||||
}
|
}
|
||||||
|
|
||||||
var refType = "DotNetCliTool".Equals(pkg.Id, StringComparison.OrdinalIgnoreCase)
|
var refType = "DotNetCliTool".Equals(pkg.PackageType, StringComparison.OrdinalIgnoreCase)
|
||||||
? "DotNetCliToolReference"
|
? "DotNetCliToolReference"
|
||||||
: "PackageReference";
|
: "PackageReference";
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue