Skip to content

Commit

Permalink
Merge pull request #68 from unoplatform/dev/jela/servicelocator-update
Browse files Browse the repository at this point in the history
chore: Update to latest CommonServiceLocator
  • Loading branch information
jeromelaban authored Mar 31, 2020
2 parents 6ef2164 + ad5d039 commit 44a7f0d
Show file tree
Hide file tree
Showing 18 changed files with 97 additions and 72 deletions.
2 changes: 1 addition & 1 deletion .azure-pipelines.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
pool:
name: 'Hosted VS2017'
vmImage: 'windows-2019'

trigger:
branches:
Expand Down
Binary file added build/uno-logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion gitversion.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
assembly-versioning-scheme: MajorMinorPatch
mode: Mainline
next-version: 1.29.0
next-version: 2.0.0

branches:
master:
Expand Down
41 changes: 41 additions & 0 deletions src/Directory.Build.props
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<Project ToolsVersion="15.0">

<PropertyGroup>
<Authors>nventive</Authors>
<PackageProjectUrl>https://github.com/nventive/Uno.Core</PackageProjectUrl>
<PackageIconUrl>https://nv-assets.azurewebsites.net/logos/uno.png</PackageIconUrl>
<RepositoryUrl>https://github.com/nventive/Uno.Core</RepositoryUrl>
<RepositoryUrl>$(BUILD_REPOSITORY_URI)</RepositoryUrl>
<Copyright>Copyright (C) 2015-$([System.DateTime]::Now.ToString(`yyyy`)) nventive inc. - all rights reserved</Copyright>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<DefaultLanguage>en-US</DefaultLanguage>
<LangVersion>8.0</LangVersion>
<PackageIcon>uno-logo.png</PackageIcon>
</PropertyGroup>

<PropertyGroup>
<IsTestProject>$(MSBuildProjectName.Contains('Test'))</IsTestProject>
<IsSampleProject>$(MSBuildProjectName.Contains('Sample'))</IsSampleProject>
</PropertyGroup>

<ItemGroup>
<None Include="$(MSBuildThisFileDirectory)..\build\uno-logo.png" Pack="true" Visible="false" PackagePath="\"/>
</ItemGroup>

<Choose>
<When Condition="'$(IsTestProject)' != 'true' and '$(SourceLinkEnabled)' != 'false' and '$(IsSampleProject)' != 'true'">
<PropertyGroup>
<!-- Optional: Declare that the Repository URL can be published to NuSpec -->
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<!-- Optional: Embed source files that are not tracked by the source control manager to the PDB -->
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<!-- Optional: Include PDB in the built .nupkg -->
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0" PrivateAssets="All"/>
</ItemGroup>
</When>
</Choose>

</Project>
4 changes: 2 additions & 2 deletions src/Uno.Core.Build/Uno.Core.Build.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<PropertyGroup>
<TargetFrameworks>net46</TargetFrameworks>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<NoWarn>$(NoWarn);1998;1591;1573;1572;1574;1712;1711;1570</NoWarn>
<NoWarn>$(NoWarn);1998;1591;1573;1572;1574;1712;1711;1570;NU5128;NU5105</NoWarn>
<Description></Description>
<BuildForLiveUnitTesting>false</BuildForLiveUnitTesting>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
Expand Down Expand Up @@ -35,7 +35,7 @@
<Pack>true</Pack>
<PackagePath>build</PackagePath>
</Content>
<Content Include="..\Uno.Core\bin\$(Configuration)\net46\Microsoft.Practices.ServiceLocation.dll">
<Content Include="..\Uno.Core\bin\$(Configuration)\net46\CommonServiceLocator.dll">
<Pack>true</Pack>
<PackagePath>build</PackagePath>
</Content>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uno.Extensions;
using Uno.Conversion;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uno.Extensions;
using Uno.Conversion;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
// ******************************************************************
using System;
using System.Globalization;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uno.Extensions;
using Uno.Conversion;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uno.Extensions;
using Uno.Conversion;
Expand Down
2 changes: 1 addition & 1 deletion src/Uno.Core.Tests/Conversions/FunqAdapter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
using System;
using System.Collections.Generic;
using Funq;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;

namespace Uno.Core.Tests.Conversions
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using Uno.Extensions;
using Uno.Reflection;
Expand Down
4 changes: 0 additions & 4 deletions src/Uno.Core.Tests/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,6 @@
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;

[assembly: AssemblyCopyright("Copyright © 2017")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

[assembly: ComVisible(false)]

[assembly: Guid("b554d7e4-17fc-4909-ba06-80b5b2fb0bd1")]
2 changes: 1 addition & 1 deletion src/Uno.Core/Extensions/ExtensionsProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;

namespace Uno.Extensions
{
Expand Down
2 changes: 1 addition & 1 deletion src/Uno.Core/IServiceLocatorProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;

namespace Uno
{
Expand Down
2 changes: 1 addition & 1 deletion src/Uno.Core/Logging/LogExtensionPoint.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
//
// ******************************************************************
using System;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;
using Microsoft.Extensions.Logging;
using System.Diagnostics;

Expand Down
2 changes: 1 addition & 1 deletion src/Uno.Core/ServiceLocatorProviderExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Practices.ServiceLocation;
using CommonServiceLocator;

namespace Uno.Extensions
{
Expand Down
94 changes: 41 additions & 53 deletions src/Uno.Core/Uno.Core.csproj
Original file line number Diff line number Diff line change
@@ -1,59 +1,47 @@
<Project Sdk="MSBuild.Sdk.Extras" ToolsVersion="15.0">
<PropertyGroup>
<TargetFrameworks>uap10.0;net46;netstandard2.0</TargetFrameworks>
<AssemblyName>Uno.Core</AssemblyName>
<RootNamespace>Uno.Core</RootNamespace>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<NoWarn>$(NoWarn);1998;1591;1573;1572;1574;1712;1711;1570</NoWarn>
<BuildForLiveUnitTesting>false</BuildForLiveUnitTesting>
<DocumentationFile>bin\Release\$(TargetFramework)\Uno.Core.xml</DocumentationFile>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
<TreatSpecificWarningsAsErrors />
<DebugType>full</DebugType>
<DebugSymbols>True</DebugSymbols>
</PropertyGroup>
<PropertyGroup>
<TargetFrameworks>uap10.0;net46;netstandard2.0</TargetFrameworks>
<AssemblyName>Uno.Core</AssemblyName>
<RootNamespace>Uno.Core</RootNamespace>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<NoWarn>$(NoWarn);1998;1591;1573;1572;1574;1712;1711;1570;NU5105</NoWarn>
<BuildForLiveUnitTesting>false</BuildForLiveUnitTesting>
<DocumentationFile>bin\Release\$(TargetFramework)\Uno.Core.xml</DocumentationFile>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
<TreatSpecificWarningsAsErrors />
<DebugType>portable</DebugType>
<DebugSymbols>True</DebugSymbols>
</PropertyGroup>

<PropertyGroup>
<Description>This package provides a set of helpers and extension methods used to accelerate development.</Description>
</PropertyGroup>

<PropertyGroup>
<Authors>nventive</Authors>
<PackageProjectUrl>https://github.com/nventive/Uno.Core</PackageProjectUrl>
<PackageIconUrl>https://nv-assets.azurewebsites.net/logos/uno.png</PackageIconUrl>
<RepositoryUrl>https://github.com/nventive/Uno.Core</RepositoryUrl>
<Description>This package provides a set of helpers and extension methods used to accelerate development.</Description>
<Copyright>Copyright (C) 2015-2019 nventive inc. - all rights reserved</Copyright>
<LangVersion>7.3</LangVersion>
</PropertyGroup>
<Import Project="..\Uno.CrossTargeting.props" />
<Import Project="..\Uno.Common.props" />

<Import Project="..\Uno.CrossTargeting.props" />
<Import Project="..\Uno.Common.props" />
<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging" Version="1.1.1" />
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="4.3.0" />
<PackageReference Include="System.ValueTuple" Version="4.4.0" />
<PackageReference Include="CommonServiceLocator" Version="2.0.5" />
<PackageReference Include="System.Collections.Immutable" Version="1.3.1" />
<PackageReference Include="Uno.MonoAnalyzers" Version="1.0.0-dev.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Memory" Version="4.5.2" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Logging" Version="1.1.1" />
<PackageReference Include="System.Reflection.Emit.Lightweight" Version="4.3.0" />
<PackageReference Include="System.ValueTuple" Version="4.4.0" />
<PackageReference Include="CommonServiceLocator" Version="1.3.0">
<NoWarn>NU1701</NoWarn>
</PackageReference>
<PackageReference Include="System.Collections.Immutable" Version="1.3.1" />
<PackageReference Include="Uno.MonoAnalyzers" Version="1.0.0-dev.4">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
<PackageReference Include="System.Memory" Version="4.5.2" />
</ItemGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'uap10.0' ">
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform " Version="5.4.0" />
</ItemGroup>

<PropertyGroup Condition="'$(TargetFramework)' == 'uap10.0'">
<DefineConstants>$(DefineConstants);NETFX_CORE;WINDOWS_UWP;HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'net46'">
<DefineConstants>$(DefineConstants);HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
<DefineConstants>$(DefineConstants);HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'uap10.0'">
<DefineConstants>$(DefineConstants);NETFX_CORE;WINDOWS_UWP;HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'net46'">
<DefineConstants>$(DefineConstants);HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard2.0'">
<DefineConstants>$(DefineConstants);HAS_DICT_GETVALUEORDEFAULT</DefineConstants>
</PropertyGroup>

</Project>
2 changes: 1 addition & 1 deletion src/global.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"msbuild-sdks": {
"MSBuild.Sdk.Extras": "1.6.68"
"MSBuild.Sdk.Extras": "2.0.54"
}
}

0 comments on commit 44a7f0d

Please sign in to comment.