Skip to content

Commit

Permalink
Moving to SDK 2.0 (#205)
Browse files Browse the repository at this point in the history
* Moving to SDK 2.0

* Updating Appveyor scripts for version change.

* Moving to .Net 4.6.1

* Updating the package version to 2.0.0

* Updating version prefix to 2.0.0

* .

* .

* more versioning fixes

* Removing PackageTargetFallback since failing restore

* Removing PackageTargetFallback in test project

* appveyor.yml fix

* Appveyor version 2.0
  • Loading branch information
serkantkaraca authored Sep 22, 2017
1 parent e07755f commit eb79ffa
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 23 deletions.
6 changes: 3 additions & 3 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version: 1.0.{build}
version: 2.0.{build}
branches:
only:
- master
Expand All @@ -16,11 +16,11 @@ environment:
secure: NYwBqWBHvwwNfcKZjjLjCDSxPEVq1AH0DvJXQjVjPA/xpDT/e9SxCj4YpIMWwd+t
matrix:
# First build
- DotNetRunTime: netcoreapp1.0
- DotNetRunTime: netcoreapp2.0
azure-event-hubs-dotnet/CodeCovSecret:
secure: pmpPpo9faBysYDhkDrKv4zOm1UOmdpga7+sZEcjYOITwzph24z947KugpQMLMGrx
# Second build
- DotNetRunTime: net46
- DotNetRunTime: net461
azure-event-hubs-dotnet/SkipCodeCoverage: true
skip_commits:
files:
Expand Down
2 changes: 1 addition & 1 deletion build/build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ $configuration = if ($CONFIGURATION -ne $null) { $CONFIGURATION } else { 'Debug
$platform = if ($PLATFORM -ne $null) { $PLATFORM } else { 'Any CPU' }
$projectFolder = if ($ENV:APPVEYOR_BUILD_FOLDER -ne $null) { "$ENV:APPVEYOR_BUILD_FOLDER" } else { $(Get-Location).path }
$buildFolder = $projectFolder + '\build\'
$runtime = if ($ENV:DotNetRunTime -ne $null) { $ENV:DotNetRunTime } else { 'netcoreapp1.0' }
$runtime = if ($ENV:DotNetRunTime -ne $null) { $ENV:DotNetRunTime } else { 'netcoreapp2.0' }
$artifactsFolder = $buildFolder + 'artifacts\'
$appProject = $projectFolder + '\src\Microsoft.Azure.EventHubs\Microsoft.Azure.EventHubs.csproj'
$testProject = $projectFolder + '\test\Microsoft.Azure.EventHubs.Tests\Microsoft.Azure.EventHubs.Tests.csproj'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<Description>This is the next generation Azure Event Hubs .NET Standard Event Processor Host library. For more information about Event Hubs, see https://azure.microsoft.com/en-us/services/event-hubs/</Description>
<AssemblyTitle>Microsoft.Azure.EventHubs.Processor</AssemblyTitle>
<VersionPrefix>1.0.3</VersionPrefix>
<VersionPrefix>2.0.0</VersionPrefix>
<Authors>Microsoft</Authors>
<TargetFrameworks>net451;netstandard1.3;uap10.0;</TargetFrameworks>
<TargetFrameworks>net461;netstandard2.0;uap10.0;</TargetFrameworks>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<AssemblyName>Microsoft.Azure.EventHubs.Processor</AssemblyName>
<AssemblyOriginatorKeyFile>../../build/keyfile.snk</AssemblyOriginatorKeyFile>
Expand All @@ -18,13 +18,14 @@
<PackageProjectUrl>https://github.com/Azure/azure-event-hubs-dotnet</PackageProjectUrl>
<PackageLicenseUrl>https://raw.githubusercontent.com/Azure/azure-event-hubs-dotnet/master/LICENSE</PackageLicenseUrl>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<PackageTargetFallback Condition=" '$(TargetFramework)' == 'netstandard1.3' ">$(PackageTargetFallback);dnxcore50;portable-net451+win8</PackageTargetFallback>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<DebugType>full</DebugType>
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\Microsoft.Azure.EventHubs.Processor.xml</DocumentationFile>
<Version>1.0.3</Version>
<Version>2.0.0</Version>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<FileVersion>2.0.0.0</FileVersion>
</PropertyGroup>

<PropertyGroup Condition="'$(TargetFramework)' == 'uap10.0'">
Expand All @@ -46,7 +47,7 @@
<PackageReference Include="WindowsAzure.Storage" Version="8.1.1" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'net451' ">
<ItemGroup Condition=" '$(TargetFramework)' == 'net461' ">
<Reference Include="System" />
<Reference Include="Microsoft.CSharp" />
</ItemGroup>
Expand Down
15 changes: 8 additions & 7 deletions src/Microsoft.Azure.EventHubs/Microsoft.Azure.EventHubs.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
<PropertyGroup>
<Description>This is the next generation Azure Event Hubs .NET Standard client library. For more information about Event Hubs, see https://azure.microsoft.com/en-us/services/event-hubs/</Description>
<AssemblyTitle>Microsoft.Azure.EventHubs</AssemblyTitle>
<VersionPrefix>1.0.3</VersionPrefix>
<VersionPrefix>2.0.0</VersionPrefix>
<Authors>Microsoft</Authors>
<TargetFrameworks>net451;netstandard1.3;uap10.0</TargetFrameworks>
<TargetFrameworks>net461;netstandard2.0;uap10.0</TargetFrameworks>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<AssemblyName>Microsoft.Azure.EventHubs</AssemblyName>
<AssemblyOriginatorKeyFile>../../build/keyfile.snk</AssemblyOriginatorKeyFile>
Expand All @@ -18,14 +18,15 @@
<PackageProjectUrl>https://github.com/Azure/azure-event-hubs-dotnet</PackageProjectUrl>
<PackageLicenseUrl>https://raw.githubusercontent.com/Azure/azure-event-hubs-dotnet/master/LICENSE</PackageLicenseUrl>
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
<PackageTargetFallback Condition=" '$(TargetFramework)' == 'netstandard1.3' ">$(PackageTargetFallback);dnxcore50</PackageTargetFallback>
<NetStandardImplicitPackageVersion Condition=" '$(TargetFramework)' == 'netstandard1.3' ">1.6.1</NetStandardImplicitPackageVersion>
<NetStandardImplicitPackageVersion Condition=" '$(TargetFramework)' == 'netstandard2.0' ">2.0.0</NetStandardImplicitPackageVersion>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<DebugType>full</DebugType>
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\Microsoft.Azure.EventHubs.xml</DocumentationFile>
<Version>1.0.3</Version>
<Version>2.0.0</Version>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
<FileVersion>2.0.0.0</FileVersion>
</PropertyGroup>

<PropertyGroup Condition="'$(TargetFramework)' == 'uap10.0'">
Expand All @@ -38,12 +39,12 @@
<TargetFrameworkVersion>v5.0</TargetFrameworkVersion>
</PropertyGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'net451' ">
<ItemGroup Condition=" '$(TargetFramework)' == 'net461' ">
<Reference Include="System" />
<Reference Include="Microsoft.CSharp" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard1.3' ">
<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard2.0' ">
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.3.0" />
<PackageReference Include="System.Runtime.Serialization.Primitives" Version="4.3.0" />
</ItemGroup>
Expand Down
4 changes: 2 additions & 2 deletions src/Microsoft.Azure.EventHubs/Primitives/ClientInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ static ClientInfo()
product = GetAssemblyAttributeValue<AssemblyProductAttribute>(assembly, p => p.Product);
version = GetAssemblyAttributeValue<AssemblyFileVersionAttribute>(assembly, v => v.Version);
framework = GetAssemblyAttributeValue<TargetFrameworkAttribute>(assembly, f => f.FrameworkName);
#if NETSTANDARD1_3
#if NETSTANDARD2_0
platform = System.Runtime.InteropServices.RuntimeInformation.OSDescription;
#elif UAP10_0
platform = "UAP";
#elif NET451
#elif NET461
platform = Environment.OSVersion.VersionString;
#endif
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,26 +1,24 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>netcoreapp1.0;net46</TargetFrameworks>
<TargetFrameworks>netcoreapp2.0;net461</TargetFrameworks>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<AssemblyName>Microsoft.Azure.EventHubs.Tests</AssemblyName>
<AssemblyOriginatorKeyFile>../../build/keyfile.snk</AssemblyOriginatorKeyFile>
<SignAssembly>true</SignAssembly>
<PublicSign Condition=" '$(OS)' != 'Windows_NT' ">true</PublicSign>
<PackageId>Microsoft.Azure.EventHubs.Tests</PackageId>
<GenerateRuntimeConfigurationFiles>true</GenerateRuntimeConfigurationFiles>
<PackageTargetFallback Condition=" '$(TargetFramework)' == 'netcoreapp1.0' ">$(PackageTargetFallback);dnxcore50;portable-net46+win8</PackageTargetFallback>
<RuntimeFrameworkVersion Condition=" '$(TargetFramework)' == 'netcoreapp1.0' ">1.0.4</RuntimeFrameworkVersion>
<GenerateAssemblyConfigurationAttribute>false</GenerateAssemblyConfigurationAttribute>
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.0.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.3.0" />
<PackageReference Include="System.Net.WebSockets.Client" Version="4.0.0" />
<PackageReference Include="xunit.runner.visualstudio" Version="2.2.0" />
<PackageReference Include="Microsoft.NETCore.Platforms" Version="1.1.0" />
<PackageReference Include="Microsoft.NETCore.Platforms" Version="2.0.0" />
<PackageReference Include="xunit" Version="2.2.0" />
<PackageReference Include="Microsoft.Extensions.PlatformAbstractions" Version="1.1.0" />
</ItemGroup>
Expand Down

0 comments on commit eb79ffa

Please sign in to comment.