-
Notifications
You must be signed in to change notification settings - Fork 0
/
Common.Targets
48 lines (40 loc) · 1.84 KB
/
Common.Targets
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<?xml version="1.0" encoding="utf-8"?>
<!--
==================================================
Common file for VS and external build files
==================================================
-->
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5">
<!-- This file must be imported first -->
<Import Project="Settings.proj" Condition="$(ToolsPath) == ''"/>
<!-- Add additional depends to Build target -->
<PropertyGroup>
<BuildDependsOn>
$(BuildDependsOn);
SayHi;
</BuildDependsOn>
</PropertyGroup>
<!-- Import 3rd party targets -->
<Import Project="$(MSBuildExtensionsPath)\MSBuildCommunityTasks\MSBuild.Community.Tasks.Targets" Condition="$(MSBuildCommunityTasksLib) == ''"/>
<Import Project="$(MSBuildExtensionsPath)\rod.Commons\rod.Commons.Targets" Condition="$(RodCommonsTargetsIsLoaded) == ''" />
<Target Name="BeforeCompile" DependsOnTargets="SetIsCompileUpToDate">
<CallTarget Targets="IncludeGeneratedAssemblyInfo" Condition="$(IsCompileUpToDate) == 'false'" />
</Target>
<Target Name="SayHi" Condition="$(IsCompileUpToDate) == 'false'" >
<Message Text="Project $(ProjectName) says 'HI' to everyone. " Importance="High" />
<Beep/>
</Target>
<Target Name="Test" DependsOnTargets="Build;GetTestAssemblies" >
<CallTarget Targets="InternalNUnit" />
</Target>
<Target Name="GetTestAssemblies" DependsOnTargets="Build">
<ItemGroup>
<Assemblies Include="$(TargetDir)$(TargetName)*.dll" />
</ItemGroup>
<RegexMatch Input="@(Assemblies)" Expression="$(TestDetectionExpression)[\.]dll$">
<Output TaskParameter="Output" ItemName="TestAssemblies"/>
</RegexMatch>
</Target>
<!-- User targets can be run as the lastest -->
<Import Condition="Exists('$(RootPath)\Common.User.Targets')" Project="$(RootPath)\Common.User.Targets" />
</Project>