Skip to content

Commit

Permalink
Update resgen, typegen to use .Net Core 2.1 (PowerShell#8369)
Browse files Browse the repository at this point in the history
  • Loading branch information
bergmeister authored and daxian-dbw committed Dec 4, 2018
1 parent 13cf8af commit 7c021e4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -597,9 +597,9 @@ protected override void EndProcessing()

#region LoadAssembly

// We now ship the NetCoreApp2.0 reference assemblies with PowerShell Core, so that Add-Type can work
// We now ship .Net Core's reference assemblies with PowerShell Core, so that Add-Type can work
// in a predictable way and won't be broken when we move to newer version of .NET Core.
// The NetCoreApp2.0 reference assemblies are located at '$PSHOME\ref'.
// The reference assemblies are located at '$PSHOME\ref'.
private static string s_netcoreAppRefFolder = PathType.Combine(PathType.GetDirectoryName(typeof(PSObject).Assembly.Location), "ref");
private static string s_frameworkFolder = PathType.GetDirectoryName(typeof(object).Assembly.Location);

Expand Down Expand Up @@ -655,7 +655,7 @@ private void LoadAssemblies(IEnumerable<string> assemblies)
/// </summary>
private static IEnumerable<PortableExecutableReference> InitDefaultRefAssemblies()
{
// netcoreapp2.0 currently comes with 137 reference assemblies (maybe more in future), so we use a capacity of '150'.
// netcoreapp2.1 currently comes with 144 reference assemblies (maybe more in future), so we use a capacity of '150'.
var defaultRefAssemblies = new List<PortableExecutableReference>(150);

foreach (string file in Directory.EnumerateFiles(s_netcoreAppRefFolder, "*.dll", SearchOption.TopDirectoryOnly))
Expand Down
2 changes: 1 addition & 1 deletion src/ResGen/ResGen.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<Description>Generates C# typed bindings for .resx files</Description>
<TargetFramework>netcoreapp2.0</TargetFramework>
<TargetFramework>netcoreapp2.1</TargetFramework>
<AssemblyName>resgen</AssemblyName>
<OutputType>Exe</OutputType>
<TieredCompilation>true</TieredCompilation>
Expand Down
2 changes: 1 addition & 1 deletion src/TypeCatalogGen/TypeCatalogGen.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<Description>Generates CorePsTypeCatalog.cs given powershell.inc</Description>
<TargetFramework>netcoreapp2.0</TargetFramework>
<TargetFramework>netcoreapp2.1</TargetFramework>
<AssemblyName>TypeCatalogGen</AssemblyName>
<OutputType>Exe</OutputType>
<TieredCompilation>true</TieredCompilation>
Expand Down
2 changes: 1 addition & 1 deletion tools/packaging/project/package.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@
<NuspecProperties>runtime=$(RID);version=$(SemVer);PackageName=$(PackageName)</NuspecProperties>
<NuspecBasePath>$(StagingPath)</NuspecBasePath>
<IsTool>True</IsTool>
<TargetFramework>netcoreapp2.0</TargetFramework>
<TargetFramework>netcoreapp2.1</TargetFramework>
</PropertyGroup>
</Project>

0 comments on commit 7c021e4

Please sign in to comment.