mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-04-05 21:01:35 +08:00
Orchard.proj and ClickToBuild.cmd: Adding additional parameter to build using a custom solution. Fixes #6627
This commit is contained in:
parent
9f4b842df2
commit
ede741b9df
@ -23,13 +23,14 @@ echo "Unable to detect suitable environment. Build may not succeed."
|
|||||||
|
|
||||||
SET target=%1
|
SET target=%1
|
||||||
SET project=%2
|
SET project=%2
|
||||||
|
SET solution=%3
|
||||||
|
|
||||||
IF "%target%" == "" SET target=Build
|
IF "%target%" == "" SET target=Build
|
||||||
IF "%project%" =="" SET project=Orchard.proj
|
IF "%project%" == "" SET project=Orchard.proj
|
||||||
|
IF "%solution%" == "" SET solution=src\Orchard.sln
|
||||||
|
|
||||||
lib\nuget\nuget.exe restore .\src\Orchard.sln
|
lib\nuget\nuget.exe restore %solution%
|
||||||
|
|
||||||
msbuild /t:%target% %project%
|
msbuild /t:%target% %project% /p:Solution=%solution%
|
||||||
|
|
||||||
pause
|
|
||||||
|
|
||||||
|
pause
|
19
Orchard.proj
19
Orchard.proj
@ -28,6 +28,9 @@
|
|||||||
<BuildPlatform Condition="$(ProgramW6432) != ''">x64</BuildPlatform>
|
<BuildPlatform Condition="$(ProgramW6432) != ''">x64</BuildPlatform>
|
||||||
<BuildPlatform Condition="$(BuildPlatform) == ''">x86</BuildPlatform>
|
<BuildPlatform Condition="$(BuildPlatform) == ''">x86</BuildPlatform>
|
||||||
<Configuration Condition="$(Configuration) == ''">Release</Configuration>
|
<Configuration Condition="$(Configuration) == ''">Release</Configuration>
|
||||||
|
|
||||||
|
<OrchardSolution>$(SrcFolder)\Orchard.sln</OrchardSolution>
|
||||||
|
<Solution Condition="$(Solution) == ''">$(OrchardSolution)</Solution>
|
||||||
|
|
||||||
<!-- TeamCity build number -->
|
<!-- TeamCity build number -->
|
||||||
<Version>$(BUILD_NUMBER)</Version>
|
<Version>$(BUILD_NUMBER)</Version>
|
||||||
@ -38,11 +41,11 @@
|
|||||||
|
|
||||||
<!-- Coordinating Targets -->
|
<!-- Coordinating Targets -->
|
||||||
|
|
||||||
<Target Name ="Build">
|
<Target Name="Build">
|
||||||
<CallTarget Targets="Clean"/>
|
<CallTarget Targets="Clean"/>
|
||||||
<CallTarget Targets="Compile"/>
|
<CallTarget Targets="Compile"/>
|
||||||
<CallTarget Targets="Test"/>
|
<CallTarget Targets="Test"/>
|
||||||
<CallTarget Targets="Package"/>
|
<CallTarget Targets="Package"/>
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name="FastBuild">
|
<Target Name="FastBuild">
|
||||||
@ -107,7 +110,7 @@
|
|||||||
<!-- Building -->
|
<!-- Building -->
|
||||||
|
|
||||||
<Target Name="Clean">
|
<Target Name="Clean">
|
||||||
<MSBuild Projects="$(SrcFolder)\Orchard.sln" Targets="Clean" />
|
<MSBuild Projects="$(Solution)" Targets="Clean" />
|
||||||
<RemoveDir Directories="$(BuildFolder)" ContinueOnError="true"/>
|
<RemoveDir Directories="$(BuildFolder)" ContinueOnError="true"/>
|
||||||
<RemoveDir Directories="$(ArtifactsFolder)" />
|
<RemoveDir Directories="$(ArtifactsFolder)" />
|
||||||
</Target>
|
</Target>
|
||||||
@ -115,16 +118,16 @@
|
|||||||
<Target Name="Compile">
|
<Target Name="Compile">
|
||||||
<!-- Compile to "OutputFolder" -->
|
<!-- Compile to "OutputFolder" -->
|
||||||
<MSBuild
|
<MSBuild
|
||||||
Projects="$(SrcFolder)\Orchard.sln"
|
Projects="$(Solution)"
|
||||||
Targets="Build"
|
Targets="Build"
|
||||||
Properties="Configuration=$(Configuration);OutputPath=$(CompileFolder)" />
|
Properties="Configuration=$(Configuration);OutputPath=$(CompileFolder)" />
|
||||||
<!-- Compile to "regular" output folder for devs using VS locally -->
|
<!-- Compile to "regular" output folder for devs using VS locally -->
|
||||||
<MSBuild
|
<MSBuild
|
||||||
Projects="$(SrcFolder)\Orchard.sln"
|
Projects="$(Solution)"
|
||||||
Targets="Build"/>
|
Targets="Build"/>
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name ="CompileMsBuildTasks">
|
<Target Name="CompileMsBuildTasks">
|
||||||
<MSBuild
|
<MSBuild
|
||||||
Projects="$(SrcFolder)\Tools\MSBuild.Orchard.Tasks\MSBuild.Orchard.Tasks.csproj"
|
Projects="$(SrcFolder)\Tools\MSBuild.Orchard.Tasks\MSBuild.Orchard.Tasks.csproj"
|
||||||
Targets="Build"
|
Targets="Build"
|
||||||
@ -145,7 +148,7 @@
|
|||||||
|
|
||||||
<!-- Testing -->
|
<!-- Testing -->
|
||||||
|
|
||||||
<Target Name ="Test">
|
<Target Name="Test">
|
||||||
<!-- TeamCity support -->
|
<!-- TeamCity support -->
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<NUnitAddinFiles Include="$(teamcity_dotnet_nunitaddin)-2.5.2.*" />
|
<NUnitAddinFiles Include="$(teamcity_dotnet_nunitaddin)-2.5.2.*" />
|
||||||
@ -160,7 +163,7 @@
|
|||||||
<NUnit Assemblies="@(TestAssemblies)" ToolPath="$(LibFolder)\nunit" WorkingDirectory="$(CompileFolder)" OutputXmlFile="$(BuildFolder)\Orchard.Tests.xml" ExcludeCategory="longrunning" />
|
<NUnit Assemblies="@(TestAssemblies)" ToolPath="$(LibFolder)\nunit" WorkingDirectory="$(CompileFolder)" OutputXmlFile="$(BuildFolder)\Orchard.Tests.xml" ExcludeCategory="longrunning" />
|
||||||
</Target>
|
</Target>
|
||||||
|
|
||||||
<Target Name ="Spec" DependsOnTargets="Package-Stage">
|
<Target Name="Spec" DependsOnTargets="Package-Stage">
|
||||||
<!-- TeamCity support -->
|
<!-- TeamCity support -->
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<NUnitAddinFiles Include="$(teamcity_dotnet_nunitaddin)-2.5.2.*" />
|
<NUnitAddinFiles Include="$(teamcity_dotnet_nunitaddin)-2.5.2.*" />
|
||||||
|
Loading…
Reference in New Issue
Block a user