Skip to content

Commit ad55636

Browse files
author
Michael Hallett
committed
Updated the build DLL in the .nuget dir and added the copy for the signed implementation; Added copy post-build actions to keep the build DLLs updated; Added a reference to the build DLL in the RestSharp project to make sure it was built first; Added additional scripts to create the nuget packages;
1 parent b803a6d commit ad55636

11 files changed

+81
-66
lines changed

.nuget/RestSharp.Build.dll

0 Bytes
Binary file not shown.

.nuget/Signed/RestSharp.Build.dll

7.5 KB
Binary file not shown.

RestSharp.Build/RestSharp.Build.Signed.csproj

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<DebugType>full</DebugType>
2020
<Optimize>false</Optimize>
2121
<OutputPath>bin\DebugSigned\</OutputPath>
22-
<IntermediateOutputPath>obj\DebugSigned\</IntermediateOutputPath>
22+
<IntermediateOutputPath>obj\DebugSigned\</IntermediateOutputPath>
2323
<DefineConstants>TRACE;DEBUG;SIGNED</DefineConstants>
2424
<ErrorReport>prompt</ErrorReport>
2525
<WarningLevel>4</WarningLevel>
@@ -29,7 +29,7 @@
2929
<DebugType>pdbonly</DebugType>
3030
<Optimize>true</Optimize>
3131
<OutputPath>bin\ReleaseSigned\</OutputPath>
32-
<IntermediateOutputPath>obj\ReleaseSigned\</IntermediateOutputPath>
32+
<IntermediateOutputPath>obj\ReleaseSigned\</IntermediateOutputPath>
3333
<DefineConstants>TRACE;SIGNED</DefineConstants>
3434
<ErrorReport>prompt</ErrorReport>
3535
<WarningLevel>4</WarningLevel>
@@ -51,6 +51,9 @@
5151
<Compile Include="Properties\AssemblyInfo.cs" />
5252
</ItemGroup>
5353
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
54+
<PropertyGroup>
55+
<PostBuildEvent>copy /Y $(TargetPath) $(SolutionDir).nuget\Signed\$(TargetFileName)</PostBuildEvent>
56+
</PropertyGroup>
5457
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
5558
Other similar extension points exist, see Microsoft.Common.targets.
5659
<Target Name="BeforeBuild">

RestSharp.Build/RestSharp.Build.csproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@
4949
<Compile Include="Properties\AssemblyInfo.cs" />
5050
</ItemGroup>
5151
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
52+
<PropertyGroup>
53+
<PostBuildEvent>copy /Y $(TargetPath) $(SolutionDir).nuget\$(TargetFileName)</PostBuildEvent>
54+
</PropertyGroup>
5255
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
5356
Other similar extension points exist, see Microsoft.Common.targets.
5457
<Target Name="BeforeBuild">

RestSharp.Signed.sln

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
21
Microsoft Visual Studio Solution File, Format Version 12.00
32
# Visual Studio 2013
43
VisualStudioVersion = 12.0.30723.0
54
MinimumVisualStudioVersion = 10.0.40219.1
65
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet", "NuGet", "{E709A928-A45C-4622-A35C-CCD8EE44CA80}"
76
ProjectSection(SolutionItems) = preProject
87
package.cmd = package.cmd
8+
packageAll.cmd = packageAll.cmd
9+
packageSigned.cmd = packageSigned.cmd
910
readme.txt = readme.txt
1011
restsharp.nuspec = restsharp.nuspec
1112
EndProjectSection
@@ -24,19 +25,19 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Meta", "Meta", "{C5B02FAA-6
2425
releasenotes.markdown = releasenotes.markdown
2526
EndProjectSection
2627
EndProject
27-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp", "RestSharp\RestSharp.Signed.csproj", "{2ECECFBF-5F3E-40EE-A963-72336DC7ABE2}"
28+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Signed", "RestSharp\RestSharp.Signed.csproj", "{2ECECFBF-5F3E-40EE-A963-72336DC7ABE2}"
2829
EndProject
29-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Tests", "RestSharp.Tests\RestSharp.Tests.Signed.csproj", "{1464E4AC-18BB-4F23-8A0B-68196F9E1871}"
30+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Tests.Signed", "RestSharp.Tests\RestSharp.Tests.Signed.csproj", "{1464E4AC-18BB-4F23-8A0B-68196F9E1871}"
3031
EndProject
31-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.IntegrationTests", "RestSharp.IntegrationTests\RestSharp.IntegrationTests.Signed.csproj", "{47D3EBB9-0300-4AF8-BAC5-740D51454A63}"
32+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.IntegrationTests.Signed", "RestSharp.IntegrationTests\RestSharp.IntegrationTests.Signed.csproj", "{47D3EBB9-0300-4AF8-BAC5-740D51454A63}"
3233
EndProject
3334
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Silverlight", "RestSharp.Silverlight\RestSharp.Silverlight.csproj", "{11F84600-0978-48B9-A28F-63B3781E54B3}"
3435
EndProject
3536
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.WindowsPhone", "RestSharp.WindowsPhone\RestSharp.WindowsPhone.csproj", "{F4D48DF6-316E-4963-B5C1-59CA39B431B7}"
3637
EndProject
37-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Net4", "RestSharp.Net4\RestSharp.Net4.Signed.csproj", "{5FF943A5-260F-4042-B4CE-C4977BAD4EBB}"
38+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Net4.Signed", "RestSharp.Net4\RestSharp.Net4.Signed.csproj", "{5FF943A5-260F-4042-B4CE-C4977BAD4EBB}"
3839
EndProject
39-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Build", "RestSharp.Build\RestSharp.Build.Signed.csproj", "{CCC30138-3D68-44D8-AF1A-D22F769EE8DC}"
40+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RestSharp.Build.Signed", "RestSharp.Build\RestSharp.Build.Signed.csproj", "{CCC30138-3D68-44D8-AF1A-D22F769EE8DC}"
4041
EndProject
4142
Global
4243
GlobalSection(SolutionConfigurationPlatforms) = preSolution

RestSharp.sln

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
1-
21
Microsoft Visual Studio Solution File, Format Version 12.00
32
# Visual Studio 2013
43
VisualStudioVersion = 12.0.30723.0
54
MinimumVisualStudioVersion = 10.0.40219.1
65
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet", "NuGet", "{E709A928-A45C-4622-A35C-CCD8EE44CA80}"
76
ProjectSection(SolutionItems) = preProject
87
package.cmd = package.cmd
8+
packageAll.cmd = packageAll.cmd
9+
packageSigned.cmd = packageSigned.cmd
910
readme.txt = readme.txt
1011
restsharp.nuspec = restsharp.nuspec
1112
EndProjectSection

RestSharp/RestSharp.Signed.csproj

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<DebugType>full</DebugType>
4242
<Optimize>false</Optimize>
4343
<OutputPath>bin\DebugSigned\</OutputPath>
44-
<IntermediateOutputPath>obj\DebugSigned\</IntermediateOutputPath>
44+
<IntermediateOutputPath>obj\DebugSigned\</IntermediateOutputPath>
4545
<DefineConstants>TRACE;DEBUG;FRAMEWORK, SIGNED</DefineConstants>
4646
<ErrorReport>prompt</ErrorReport>
4747
<WarningLevel>4</WarningLevel>
@@ -54,7 +54,7 @@
5454
<DebugType>pdbonly</DebugType>
5555
<Optimize>true</Optimize>
5656
<OutputPath>bin\ReleaseSigned\</OutputPath>
57-
<IntermediateOutputPath>obj\ReleaseSigned\</IntermediateOutputPath>
57+
<IntermediateOutputPath>obj\ReleaseSigned\</IntermediateOutputPath>
5858
<DefineConstants>TRACE;FRAMEWORK, SIGNED</DefineConstants>
5959
<ErrorReport>prompt</ErrorReport>
6060
<WarningLevel>4</WarningLevel>
@@ -199,6 +199,12 @@
199199
<Install>true</Install>
200200
</BootstrapperPackage>
201201
</ItemGroup>
202+
<ItemGroup>
203+
<ProjectReference Include="..\RestSharp.Build\RestSharp.Build.Signed.csproj">
204+
<Project>{ccc30138-3d68-44d8-af1a-d22f769ee8dc}</Project>
205+
<Name>RestSharp.Build.Signed</Name>
206+
</ProjectReference>
207+
</ItemGroup>
202208
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
203209
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
204210
<PropertyGroup>
@@ -212,7 +218,7 @@
212218
<Target Name="AfterBuild">
213219
</Target>
214220
-->
215-
<UsingTask TaskName="NuSpecUpdateTask" AssemblyFile="$(SolutionDir).nuget\RestSharp.Build.dll" />
221+
<UsingTask TaskName="NuSpecUpdateTask" AssemblyFile="$(SolutionDir).nuget\Signed\RestSharp.Build.dll" />
216222
<Target Name="AfterBuild" Condition="$(Configuration) == Release">
217223
<NuSpecUpdateTask SpecFile="$(SolutionDir)restsharp.nuspec" SourceAssemblyFile="$(TargetDir)RestSharp.dll" />
218224
</Target>

RestSharp/RestSharp.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -188,6 +188,12 @@
188188
<Install>true</Install>
189189
</BootstrapperPackage>
190190
</ItemGroup>
191+
<ItemGroup>
192+
<ProjectReference Include="..\RestSharp.Build\RestSharp.Build.csproj">
193+
<Project>{ccc30138-3d68-44d8-af1a-d22f769ee8dc}</Project>
194+
<Name>RestSharp.Build</Name>
195+
</ProjectReference>
196+
</ItemGroup>
191197
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
192198
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
193199
<PropertyGroup>

package.cmd

Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
echo Buiding Unsigned Package
2-
31
%windir%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe RestSharp.sln /t:Clean,Rebuild /p:Configuration=Release /fileLogger
42

53
if not exist Download\Net4 mkdir Download\Net4\
@@ -49,55 +47,3 @@ copy RestSharp.WindowsPhone\bin\Release\RestSharp.WindowsPhone.xml Download\Pack
4947
tools\nuget.exe update -self
5048
tools\nuget.exe pack restsharp-computed.nuspec -BasePath Download\Package -Output Download
5149
del restsharp-computed.nuspec
52-
53-
echo Buiding Signed Package
54-
55-
%windir%\Microsoft.NET\Framework\v4.0.30319\msbuild.exe RestSharp.Signed.sln /t:Clean,Rebuild /p:Configuration=Release /fileLogger
56-
57-
if not exist DownloadSigned\Net4 mkdir DownloadSigned\Net4\
58-
if not exist DownloadSigned\Silverlight mkdir DownloadSigned\Silverlight\
59-
if not exist DownloadSigned\WindowsPhone mkdir DownloadSigned\WindowsPhone\
60-
if not exist DownloadSigned\package\lib\net35 mkdir DownloadSigned\package\lib\net35\
61-
if not exist DownloadSigned\package\lib\net35-client mkdir DownloadSigned\package\lib\net35-client\
62-
if not exist DownloadSigned\package\lib\net4 mkdir DownloadSigned\package\lib\net4\
63-
if not exist DownloadSigned\package\lib\net4-client mkdir DownloadSigned\package\lib\net4-client\
64-
if not exist DownloadSigned\package\lib\sl4-wp71 mkdir DownloadSigned\package\lib\sl4-wp71\
65-
if not exist DownloadSigned\package\lib\sl4 mkdir DownloadSigned\package\lib\sl4\
66-
67-
copy RestSharp\bin\ReleaseSigned\RestSharp.dll DownloadSigned\
68-
copy RestSharp\bin\ReleaseSigned\RestSharp.xml DownloadSigned\
69-
70-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.dll DownloadSigned\Net4\
71-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.xml DownloadSigned\Net4\
72-
73-
copy RestSharp.Silverlight\bin\Release\RestSharp.Silverlight.dll DownloadSigned\Silverlight\
74-
copy RestSharp.Silverlight\bin\Release\RestSharp.Silverlight.xml DownloadSigned\Silverlight\
75-
76-
copy RestSharp.WindowsPhone\bin\Release\RestSharp.WindowsPhone.dll DownloadSigned\WindowsPhone\
77-
copy RestSharp.WindowsPhone\bin\Release\RestSharp.WindowsPhone.xml DownloadSigned\WindowsPhone\
78-
79-
copy LICENSE.txt DownloadSigned\
80-
copy readme.txt DownloadSigned\
81-
copy readme.txt DownloadSigned\package\
82-
83-
copy RestSharp\bin\ReleaseSigned\RestSharp.dll DownloadSigned\Package\lib\net35\
84-
copy RestSharp\bin\ReleaseSigned\RestSharp.dll DownloadSigned\Package\lib\net35-client\
85-
86-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.dll DownloadSigned\Package\lib\net4\
87-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.dll DownloadSigned\Package\lib\net4-client\
88-
89-
copy RestSharp.Silverlight\bin\Release\RestSharp.Silverlight.dll DownloadSigned\Package\lib\sl4\
90-
copy RestSharp.WindowsPhone\bin\Release\RestSharp.WindowsPhone.dll DownloadSigned\Package\lib\sl4-wp71\
91-
92-
copy RestSharp\bin\ReleaseSigned\RestSharp.xml DownloadSigned\Package\lib\net35\
93-
copy RestSharp\bin\ReleaseSigned\RestSharp.xml DownloadSigned\Package\lib\net35-client\
94-
95-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.xml DownloadSigned\Package\lib\net4\
96-
copy RestSharp.Net4\bin\ReleaseSigned\RestSharp.xml DownloadSigned\Package\lib\net4-client\
97-
98-
copy RestSharp.Silverlight\bin\Release\RestSharp.Silverlight.xml DownloadSigned\Package\lib\sl4\
99-
copy RestSharp.WindowsPhone\bin\Release\RestSharp.WindowsPhone.xml DownloadSigned\Package\lib\sl4-wp71\
100-
101-
tools\nuget.exe update -self
102-
tools\nuget.exe pack restsharp-computed.nuspec -BasePath DownloadSigned\Package -Output DownloadSigned
103-
del restsharp-computed.nuspec

packageAll.cmd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
package.cmd & packageSigned.cmd

0 commit comments

Comments
 (0)