Skip to content

Upgrade from .Net Core 1.x to 2.0.5 runtime (using SDK 2.1.4) #853

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 32 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
ebfd39a
Upgrade to .Net Core SDK 1.1.5
bergmeister Dec 1, 2017
647b40f
fix restore
bergmeister Dec 1, 2017
0e49065
use newer vs 2017 image instead of wmf5
bergmeister Dec 1, 2017
1afcaa7
do not install pester for new image because it is already installed
bergmeister Dec 1, 2017
a14aef3
replace project.json reference with new csproj in build.ps1
bergmeister Dec 1, 2017
46ba6cc
Fix problem with ressource binding
bergmeister Dec 1, 2017
0fea264
csproj xml syntax fix
bergmeister Dec 2, 2017
6312e12
install .net sdk 1.1 for legacy wmf4 image
bergmeister Dec 2, 2017
0af69ea
add missing parenthesis
bergmeister Dec 2, 2017
4b25140
use iwr instead of bitstransfer for wmf4 build due to mixed assembly …
bergmeister Dec 2, 2017
d9fb6bd
Update appveyor.yml
bergmeister Dec 2, 2017
870ecde
correct iwr syntax do downlod dotnet-install
bergmeister Dec 2, 2017
94799b3
correct syntax to install dotnet
bergmeister Dec 2, 2017
9454073
install pester for wmf 4 build
bergmeister Dec 2, 2017
17c3461
appveyor syntax fix
bergmeister Dec 2, 2017
aa5d606
PowerShellGet is not available in wmf4 -> use cinst instead
bergmeister Dec 2, 2017
9ebf1b1
use fullsemver of pester to install
bergmeister Dec 2, 2017
7c27642
add cache back to appveyor
bergmeister Dec 2, 2017
c857b61
cleanup
bergmeister Dec 2, 2017
d17f63c
restore packages automatically the first time
bergmeister Dec 2, 2017
3a11662
rename VS solutions appropriately
bergmeister Dec 2, 2017
3798d45
simplify restore to do it on the solution
bergmeister Dec 2, 2017
2294b90
update download link for .net core 1.1.5 sdk
bergmeister Dec 2, 2017
fc5f218
add pester version to readme
bergmeister Dec 2, 2017
c7c3ce1
try to see if it is possible to get rid of the old solution
bergmeister Dec 2, 2017
7edf422
try to get rid of the last call to the resource generation script
bergmeister Dec 2, 2017
2ded58d
update readme with full path to out directory
bergmeister Dec 2, 2017
ff83317
remove the remainders of the ressource generation script calls and do…
bergmeister Dec 2, 2017
d1eb2ad
csproj cleanup from the old DNX or preview days
bergmeister Dec 2, 2017
d106420
upgrade from netcore 1.1 to 2.0 (same sdk version as pwsh 6.0.1)
bergmeister Jan 20, 2018
8a0d1af
update sdk to get 2.0.5 runtime (old sdk had only 2.0.0 runtime)
bergmeister Jan 20, 2018
38d600f
update appveyor installation of sdk and readme
bergmeister Jan 20, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 2 additions & 19 deletions .build.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ param(
# todo remove aliases
# todo make each project have its own build script

$resourceScript = Join-Path $BuildRoot "New-StronglyTypedCsFileForResx.ps1"
$outPath = "$BuildRoot/out"
$modulePath = "$outPath/PSScriptAnalyzer"

Expand Down Expand Up @@ -81,8 +80,8 @@ function Get-BuildTaskParams($project) {

function Get-RestoreTaskParams($project) {
@{
Inputs = "$BuildRoot/$project/project.json"
Outputs = "$BuildRoot/$project/project.lock.json"
Inputs = "$BuildRoot/$project/$project.csproj"
Outputs = "$BuildRoot/$project/$project.csproj"
Jobs = {dotnet restore}
}
}
Expand All @@ -109,20 +108,6 @@ function Get-TestTaskParam($project) {
}
}

function Get-ResourceTaskParam($project) {
@{
Inputs = "$project/Strings.resx"
Outputs = "$project/Strings.cs"
Data = $project
Jobs = {
Push-Location $BuildRoot
& $resourceScript $Task.Data
Pop-Location
}
Before = "$project/build"
}
}

function Add-ProjectTask([string]$project, [string]$taskName, [hashtable]$taskParams, [string]$pathPrefix = $buildRoot) {
$jobs = [scriptblock]::Create(@"
pushd $pathPrefix/$project
Expand All @@ -136,14 +121,12 @@ popd

$projects = @("engine", "rules")
$projects | ForEach-Object {
Add-ProjectTask $_ buildResource (Get-ResourceTaskParam $_)
Add-ProjectTask $_ build (Get-BuildTaskParams $_)
Add-ProjectTask $_ restore (Get-RestoreTaskParams $_)
Add-ProjectTask $_ clean (Get-CleanTaskParams $_)
Add-ProjectTask $_ test (Get-TestTaskParam $_) "$BuildRoot/tests"
}

task buildResource -Before build "engine/buildResource", "rules/buildResource"
task build "engine/build", "rules/build"
task restore "engine/restore", "rules/restore"
task clean "engine/clean", "rules/clean"
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ TestResult.xml
[Rr]eleasePS/
dlldata.c

# DNX
# .Net Core CLI
project.lock.json
artifacts/

Expand Down
56 changes: 56 additions & 0 deletions Engine/Engine.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<VersionPrefix>1.16.1</VersionPrefix>
<TargetFrameworks>netstandard1.6;net451</TargetFrameworks>
<AssemblyName>Microsoft.Windows.PowerShell.ScriptAnalyzer</AssemblyName>
<PackageId>Engine</PackageId>
<RootNamespace>Microsoft.Windows.PowerShell.ScriptAnalyzer</RootNamespace> <!-- Namespace needs to match Assembly name for ressource binding -->
</PropertyGroup>

<ItemGroup>
<PackageReference Include="System.Management.Automation" Version="6.0.0-alpha13" />
</ItemGroup>

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

<PropertyGroup Condition=" '$(TargetFramework)' == 'net451' ">
<DebugType>portable</DebugType>
</PropertyGroup>

<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard1.6' ">
<DefineConstants>$(DefineConstants);CORECLR</DefineConstants>
</PropertyGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard1.6' ">
<Compile Remove="SafeDirectoryCatalog.cs" />
</ItemGroup>

<ItemGroup>
<Compile Remove="Commands\GetScriptAnalyzerLoggerCommand.cs" />
</ItemGroup>

<ItemGroup>
<Compile Update="Strings.Designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>Strings.resx</DependentUpon>
</Compile>
</ItemGroup>

<ItemGroup>
<EmbeddedResource Update="Strings.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Strings.Designer.cs</LastGenOutput>
</EmbeddedResource>
</ItemGroup>

<PropertyGroup Condition=" '$(Configuration)' == 'PSV3Release' ">
<DefineConstants>$(DefineConstants);PSV3;PSV5</DefineConstants>
</PropertyGroup>

</Project>
Loading