forked from kerryjiang/WebSocket4Net
-
Notifications
You must be signed in to change notification settings - Fork 0
/
WebSocket4Net.build
26 lines (26 loc) · 1.97 KB
/
WebSocket4Net.build
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
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" DefaultTargets="Build">
<PropertyGroup>
<Configuration>Release</Configuration>
<KeyFile>..\..\..\SignKeys\websocket4net.snk</KeyFile>
</PropertyGroup>
<Target Name="Build">
<Exec Command="nuget restore WebSocket4Net.sln" />
<MSBuild Projects="WebSocket4Net\WebSocket4Net.Net20.csproj" Targets="Clean;Build" Properties="Configuration=$(Configuration);OutputPath=..\bin\net20\$(Configuration);SignAssembly=True;AssemblyOriginatorKeyFile=$(KeyFile)"/>
<MSBuild Projects="WebSocket4Net\WebSocket4Net.Net35.csproj" Targets="Clean;Build" Properties="Configuration=$(Configuration);OutputPath=..\bin\net35\$(Configuration);SignAssembly=True;AssemblyOriginatorKeyFile=$(KeyFile)"/>
<MSBuild Projects="WebSocket4Net\WebSocket4Net.Net40.csproj" Targets="Clean;Build" Properties="Configuration=$(Configuration);OutputPath=..\bin\net40\$(Configuration);SignAssembly=True;AssemblyOriginatorKeyFile=$(KeyFile)"/>
<MSBuild Projects="WebSocket4Net\WebSocket4Net.Net45.csproj" Targets="Clean;Build" Properties="Configuration=$(Configuration);OutputPath=..\bin\net45\$(Configuration);SignAssembly=True;AssemblyOriginatorKeyFile=$(KeyFile)"/>
<Exec Command="dotnet restore" WorkingDirectory="dotnet\WebSocket4Net" />
<Exec Command="dotnet build -c $(Configuration) -f netstandard1.3 -o ..\..\bin\netstandard1.3\$(Configuration) /p:SignAssembly=True /p:AssemblyOriginatorKeyFile=..\$(KeyFile)" WorkingDirectory="dotnet\WebSocket4Net" />
</Target>
<Target Name="Pack">
<GetAssemblyIdentity AssemblyFiles="bin\net20\$(Configuration)\WebSocket4Net.dll">
<Output TaskParameter="Assemblies" ItemName="myAssemblyInfo"/>
</GetAssemblyIdentity>
<Message Text="WebSocket4Net Version: %(myAssemblyInfo.Version)" />
<Exec Command="nuget pack WebSocket4Net.nuspec -Properties version=%(myAssemblyInfo.Version)"/>
</Target>
<Target Name="BuildAndPack">
<CallTarget Targets="Build"/>
<CallTarget Targets="Pack"/>
</Target>
</Project>