Skip to content
Browse files

Merge remote-tracking branch 'upstream/master'

Conflicts:
	src/Elmah-MongoDB.suo
  • Loading branch information...
2 parents b2c178b + 1b14f68 commit f882e3fcd5259f4304e5793339f7444725713176 @adamkirkton adamkirkton committed Mar 15, 2012
View
11 .gitignore
@@ -0,0 +1,11 @@
+obj
+bin
+*.user
+*.suo
+*.orig
+packages
+_ReSharper.*
+*.Resharper
+*.Cache
+*.cache
+~$*
View
4 build.cmd
@@ -1,4 +0,0 @@
-pkg\nuget\Tools\NuGet i src\Elmah.MongoDB\packages.config -o src\packages
-%windir%\Microsoft.NET\Framework\v3.5\msbuild src\Elmah-MongoDB.sln /t:Rebuild /p:Configuration=Release
-cd pkg\nuget\
-pack.cmd
View
BIN pkg/nuget/Tools/NuGet.exe
Binary file not shown.
View
2 pkg/nuget/nuspec/Elmah.MongoDB.nuspec
@@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>elmah.mongodb</id>
- <version>1.2.1</version>
+ <version>1.3.1</version>
<title>ELMAH on MongoDB (requires manual config)</title>
<authors>Simon Green</authors>
<owners>Simon Green</owners>
View
5 pkg/nuget/pack.cmd
@@ -1,5 +1,2 @@
copy ..\..\src\Elmah.MongoDB\bin\Release\Elmah.MongoDB.dll nuspec\lib\net35 /Y
-copy ..\..\src\Elmah.MongoDB\bin\Release\MongoDB.Bson.dll nuspec\lib\net35 /Y
-copy ..\..\src\Elmah.MongoDB\bin\Release\MongoDB.Driver.dll nuspec\lib\net35 /Y
-Tools\NuGet pack nuspec\Elmah.MongoDB.nuspec
-Tools\NuGet push elmah.mongodb.1.2.1.nupkg
+..\..\src\.nuget\NuGet pack nuspec\Elmah.MongoDB.nuspec
View
6 src/.nuget/NuGet.Config
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="utf-8"?>
+<configuration>
+ <solution>
+ <add key="disableSourceControlIntegration" value="true" />
+ </solution>
+</configuration>
View
BIN src/.nuget/NuGet.exe
Binary file not shown.
View
52 src/.nuget/NuGet.targets
@@ -0,0 +1,52 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <PropertyGroup>
+ <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">$(MSBuildProjectDirectory)\..\</SolutionDir>
+ <NuGetToolsPath>$([System.IO.Path]::Combine($(SolutionDir), ".nuget"))</NuGetToolsPath>
+ <NuGetExePath>$(NuGetToolsPath)\nuget.exe</NuGetExePath>
+ <PackagesConfig>$([System.IO.Path]::Combine($(ProjectDir), "packages.config"))</PackagesConfig>
+ <PackagesDir>$([System.IO.Path]::Combine($(SolutionDir), "packages"))</PackagesDir>
+ <PackageOutputDir Condition="$(PackageOutputDir) == ''">$(TargetDir.Trim('\\'))</PackageOutputDir>
+
+ <!-- Package sources used to restore packages. By default will used the registered sources under %APPDATA%\NuGet\NuGet.Config -->
+ <PackageSources>""</PackageSources>
+
+ <!-- Enable the restore command to run before builds -->
+ <RestorePackages Condition="$(RestorePackages) == ''">false</RestorePackages>
+
+ <!-- Property that enables building a package from a project -->
+ <BuildPackage Condition="$(BuildPackage) == ''">false</BuildPackage>
+
+ <!-- Commands -->
+ <RestoreCommand>"$(NuGetExePath)" install "$(PackagesConfig)" -source $(PackageSources) -o "$(PackagesDir)"</RestoreCommand>
+ <BuildCommand>"$(NuGetExePath)" pack "$(ProjectPath)" -p Configuration=$(Configuration) -o "$(PackageOutputDir)" -symbols</BuildCommand>
+
+ <!-- Make the build depend on restore packages -->
+ <BuildDependsOn Condition="$(RestorePackages) == 'true'">
+ RestorePackages;
+ $(BuildDependsOn);
+ </BuildDependsOn>
+
+ <!-- Make the build depend on restore packages -->
+ <BuildDependsOn Condition="$(BuildPackage) == 'true'">
+ $(BuildDependsOn);
+ BuildPackage;
+ </BuildDependsOn>
+ </PropertyGroup>
+
+ <Target Name="CheckPrerequisites">
+ <!-- Raise an error if we're unable to locate nuget.exe -->
+ <Error Condition="!Exists('$(NuGetExePath)')" Text="Unable to locate '$(NuGetExePath)'" />
+ </Target>
+
+ <Target Name="RestorePackages" DependsOnTargets="CheckPrerequisites">
+ <Exec Command="$(RestoreCommand)"
+ LogStandardErrorAsError="true"
+ Condition="Exists('$(PackagesConfig)')" />
+ </Target>
+
+ <Target Name="BuildPackage" DependsOnTargets="CheckPrerequisites">
+ <Exec Command="$(BuildCommand)"
+ LogStandardErrorAsError="true" />
+ </Target>
+</Project>
View
6 src/Elmah-MongoDB.sln
@@ -10,6 +10,12 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "package", "package", "{8341
..\pkg\nuget\nuspec\content\web.config.transform = ..\pkg\nuget\nuspec\content\web.config.transform
EndProjectSection
EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{F970C7E5-848D-4626-8EDA-909E98DF6653}"
+ ProjectSection(SolutionItems) = preProject
+ .nuget\NuGet.exe = .nuget\NuGet.exe
+ .nuget\NuGet.targets = .nuget\NuGet.targets
+ EndProjectSection
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
View
BIN src/Elmah-MongoDB.suo
Binary file not shown.
View
3 src/Elmah.MongoDB/Elmah.MongoDB.csproj
@@ -13,6 +13,8 @@
<TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
+ <SolutionDir Condition="$(SolutionDir) == '' Or $(SolutionDir) == '*Undefined*'">..\..\src\</SolutionDir>
+ <RestorePackages>true</RestorePackages>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
@@ -61,6 +63,7 @@
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+ <Import Project="$(SolutionDir)\.nuget\nuget.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">

0 comments on commit f882e3f

Please sign in to comment.
Something went wrong with that request. Please try again.