File tree Expand file tree Collapse file tree 2 files changed +50
-0
lines changed
tools-local/generate-graphviz Expand file tree Collapse file tree 2 files changed +50
-0
lines changed Original file line number Diff line number Diff line change 498
498
<Target Name =" GetProjectDirectory" Outputs =" $(ProjectDirectory)" />
499
499
<Target Name =" GetOrchestratedManifestBuildName" Outputs =" $(OrchestratedManifestBuildName)" />
500
500
<Target Name =" GetOfficialBuildId" Outputs =" $(OfficialBuildId)" />
501
+ <Target Name =" GetRepositoryReferences" Outputs =" @(RepositoryReference)" />
501
502
502
503
<Import Project =" $([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory).., dir.targets))/dir.targets" />
503
504
</Project >
Original file line number Diff line number Diff line change
1
+ <Project >
2
+ <Import Project =" $([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.props))/dir.props" />
3
+
4
+ <Target Name =" Build" >
5
+ <ItemGroup >
6
+ <AllRepoProjects
7
+ Include =" $(ProjectDir)repos\*.proj"
8
+ Exclude ="
9
+ $(ProjectDir)repos\known-good.proj;
10
+ $(ProjectDir)repos\known-good-tests.proj" />
11
+ </ItemGroup >
12
+
13
+ <MSBuild
14
+ Projects =" @(AllRepoProjects)"
15
+ Targets =" GetRepositoryReferences" >
16
+ <Output TaskParameter =" TargetOutputs" ItemName =" RepoReferences" />
17
+ </MSBuild >
18
+
19
+ <ItemGroup >
20
+ <RepoLink Include =" %(RepoReferences.MSBuildSourceProjectFile)" SourceRepo =" %(RepoReferences.Identity)" />
21
+ <RepoLink TargetRepo =" %(Filename)" />
22
+ <RepoLink Text =" " %(SourceRepo)" -> " %(TargetRepo)" " />
23
+ </ItemGroup >
24
+
25
+ <PropertyGroup >
26
+ <GraphVizFile >$(BaseIntermediatePath)graphviz.dot</GraphVizFile >
27
+ <GraphVizPngFile >$(BaseIntermediatePath)graphviz.png</GraphVizPngFile >
28
+ <GraphVizContent >digraph {
29
+ graph [ dpi = 150 ]
30
+ @(RepoLink -> '%(Text)')
31
+ }</GraphVizContent >
32
+ </PropertyGroup >
33
+
34
+ <WriteLinesToFile
35
+ Lines =" $(GraphVizContent)"
36
+ File =" $(GraphVizFile)"
37
+ Overwrite =" True" />
38
+
39
+ <Message Importance =" High" Text =" $(MSBuildProjectName) -> $(GraphVizFile)" />
40
+
41
+ <Exec
42
+ Condition =" '$(GraphVizDir)' != ''"
43
+ Command =" $([MSBuild]::NormalizePath('$(GraphVizDir)', 'dot')) $(GraphVizFile) -Tpng:cairo -o $(GraphVizPngFile)" />
44
+
45
+ <Message Condition =" '$(GraphVizDir)' != ''" Importance =" High" Text =" $(MSBuildProjectName) -> $(GraphVizPngFile)" />
46
+ </Target >
47
+
48
+ <Import Project =" $([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), dir.targets))/dir.targets" />
49
+ </Project >
You can’t perform that action at this time.
0 commit comments