Skip to content

Commit

Permalink
Enabled Visual Studio 2013 use.
Browse files Browse the repository at this point in the history
  • Loading branch information
ploeh committed Jan 29, 2014
1 parent b7675cf commit f6ad0ef
Show file tree
Hide file tree
Showing 7 changed files with 92 additions and 21 deletions.
10 changes: 9 additions & 1 deletion Build-Release.ps1
Original file line number Diff line number Diff line change
@@ -1 +1,9 @@
.$env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild BuildRelease.msbuild /property:Configuration=Release
function Get-VsVersion ()
{
if ($env:VS120COMNTOOLS -ne $null)
{
" /property:VisualStudioVersion=12.0"
}
}

Start-Process -NoNewWindow -Wait -FilePath $env:windir\Microsoft.NET\Framework\v4.0.30319\MSBuild -ArgumentList ('BuildRelease.msbuild', '/property:Configuration=Release', (Get-VsVersion))
19 changes: 16 additions & 3 deletions Src/Zero29.UnitTests/Zero29.UnitTests.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<AssemblyName>Ploeh.Zero29.UnitTests</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<Name>Zero29.UnitTests</Name>
<TargetFSharpCoreVersion>4.3.0.0</TargetFSharpCoreVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand All @@ -35,7 +36,19 @@
<PropertyGroup>
<MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" Condition=" Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')" />
<Choose>
<When Condition="'$(VisualStudioVersion)' == '11.0'">
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</Otherwise>
</Choose>
<Import Project="$(FSharpTargetsPath)" Condition="Exists('$(FSharpTargetsPath)')" />
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.fs" />
<None Include="packages.config" />
Expand All @@ -47,10 +60,10 @@
<Project>{1bbd593b-40e4-4ef0-bc98-2832365a4619}</Project>
<Private>True</Private>
</ProjectReference>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>True</Private>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Numerics" />
Expand Down
19 changes: 16 additions & 3 deletions Src/Zero29/Zero29.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<AssemblyName>Zero29</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<Name>Zero29</Name>
<TargetFSharpCoreVersion>4.3.0.0</TargetFSharpCoreVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand Down Expand Up @@ -39,10 +40,10 @@
<WarningsAsErrors />
</PropertyGroup>
<ItemGroup>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>True</Private>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Numerics" />
Expand All @@ -63,7 +64,19 @@
<PropertyGroup>
<MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" Condition=" Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')" />
<Choose>
<When Condition="'$(VisualStudioVersion)' == '11.0'">
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</Otherwise>
</Choose>
<Import Project="$(FSharpTargetsPath)" Condition="Exists('$(FSharpTargetsPath)')" />
<!-- 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">
Expand Down
19 changes: 16 additions & 3 deletions Src/ZeroToNine.UnitTests/ZeroToNine.UnitTests.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<AssemblyName>Ploeh.ZeroToNine.UnitTests</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<Name>ZeroToNine.UnitTests</Name>
<TargetFSharpCoreVersion>4.3.0.0</TargetFSharpCoreVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand All @@ -35,18 +36,30 @@
<PropertyGroup>
<MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" Condition=" Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')" />
<Choose>
<When Condition="'$(VisualStudioVersion)' == '11.0'">
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</Otherwise>
</Choose>
<Import Project="$(FSharpTargetsPath)" Condition="Exists('$(FSharpTargetsPath)')" />
<ItemGroup>
<Compile Include="Properties\AssemblyInfo.fs" />
<None Include="packages.config" />
<Compile Include="VersioningTests.fs" />
<Compile Include="FileSystemTests.fs" />
</ItemGroup>
<ItemGroup>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>True</Private>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Numerics" />
Expand Down
14 changes: 8 additions & 6 deletions Src/ZeroToNine.sln
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2012
# Visual Studio 2013
VisualStudioVersion = 12.0.30110.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{605E0FD8-3AEB-4C46-BBF0-26DCB80240A5}"
ProjectSection(SolutionItems) = preProject
.nuget\packages.config = .nuget\packages.config
EndProjectSection
EndProject
Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "ZeroToNine.UnitTests", "ZeroToNine.UnitTests\ZeroToNine.UnitTests.fsproj", "{A53B6476-138A-4D7A-92C9-9B3494D827C0}"
EndProject
Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "ZeroToNine", "ZeroToNine\ZeroToNine.fsproj", "{1BBD593B-40E4-4EF0-BC98-2832365A4619}"
Expand All @@ -9,11 +16,6 @@ Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "Zero29", "Zero29\Zero29.fsp
EndProject
Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "Zero29.UnitTests", "Zero29.UnitTests\Zero29.UnitTests.fsproj", "{C32C84DA-8220-4308-885C-F16F050F82B8}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{605E0FD8-3AEB-4C46-BBF0-26DCB80240A5}"
ProjectSection(SolutionItems) = preProject
.nuget\packages.config = .nuget\packages.config
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down
19 changes: 16 additions & 3 deletions Src/ZeroToNine/ZeroToNine.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
<AssemblyName>Ploeh.ZeroToNine</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<Name>ZeroToNine</Name>
<TargetFSharpCoreVersion>4.3.0.0</TargetFSharpCoreVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
Expand All @@ -35,10 +36,10 @@
<WarningsAsErrors />
</PropertyGroup>
<ItemGroup>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>True</Private>
</Reference>
<Reference Include="mscorlib" />
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Numerics" />
Expand All @@ -51,7 +52,19 @@
<PropertyGroup>
<MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
</PropertyGroup>
<Import Project="$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets" Condition=" Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')" />
<Choose>
<When Condition="'$(VisualStudioVersion)' == '11.0'">
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup>
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</Otherwise>
</Choose>
<Import Project="$(FSharpTargetsPath)" Condition="Exists('$(FSharpTargetsPath)')" />
<!-- 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">
Expand Down
13 changes: 11 additions & 2 deletions build-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,17 @@ function abspath()
echo $(cd $(dirname $1); pwd)/$(basename $1) | sed 's/^\///' | sed 's/\//\\/g' | sed 's/^./\0:/'
}

function vsvers()
{
if [ "$VS120COMNTOOLS" ]; then
echo " /property:VisualStudioVersion=12.0"
else
echo ""
fi
}

if [ "$1" != "" ]; then
$WINDIR/Microsoft.NET/Framework/v4.0.30319/MSBuild.exe /property:AssemblyOriginatorKeyFile=`abspath $1` /property:SignAssembly=true BuildRelease.msbuild /property:Configuration=Release
$WINDIR/Microsoft.NET/Framework/v4.0.30319/MSBuild.exe /property:AssemblyOriginatorKeyFile=`abspath $1` /property:SignAssembly=true BuildRelease.msbuild /property:Configuration=Release `vsvers`
else
$WINDIR/Microsoft.NET/Framework/v4.0.30319/MSBuild.exe BuildRelease.msbuild /property:Configuration=Release
$WINDIR/Microsoft.NET/Framework/v4.0.30319/MSBuild.exe BuildRelease.msbuild /property:Configuration=Release `vsvers`
fi

0 comments on commit f6ad0ef

Please sign in to comment.