mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Switch to netcoreapp1.0
Instead of using `dotnet publish`, we can use `dotnet build` and the new `netcoreapp1.0` framework with a new dependency on `Microsoft.NETCore.App` to generate output that does not include the runtime, but can be run anywhere (given the installation of the runtime). While we cannot yet adopt a dependency on the shared host until .NET Core RTM, we are forced to switch to this system anyway because the latest RC3 packages and CLI do not support `netstandardapp1.5`. See dotnet/cli#2482. Thus we're in an in-between state where we have to use `netcoreapp1.0`, but cannot use `"Microsoft.NETCore.App": { "type": "platform" }` to utilize the shared host, as we need to continue to ship our host. Without specifying "platform", we retain the status quo with respect to build steps and outputs. Additionally, there is no longer a good reason to use the RC3 packages, and it has been advised we switch to RC2 since the `Microsoft.NETCore.App` is only available for RC2. We must update packages because our current version can no longer be debugged.
This commit is contained in:
@@ -114,7 +114,7 @@ Start-PSBuild
|
||||
|
||||
Congratulations! If everything went right, PowerShell is now built.
|
||||
The `Start-PSBuild` script will output the location of the executable:
|
||||
`./src/Microsoft.PowerShell.CoreConsoleHost/bin/Linux/netstandardapp1.5/ubuntu.14.04-x64/powershell`.
|
||||
`./src/Microsoft.PowerShell.CoreConsoleHost/bin/Linux/netcoreapp1.0/ubuntu.14.04-x64/powershell`.
|
||||
|
||||
You can run our cross-platform Pester tests with `Start-PSPester`, and
|
||||
our xUnit tests with `Start-PSxUnit`.
|
||||
@@ -160,7 +160,7 @@ dotnet build --configuration Linux
|
||||
|
||||
The executable will be in
|
||||
`./bin/[configuration]/[framework]/[rid]/[binary name]`, where our
|
||||
configuration is `Linux`, framework is `netstandardapp1.5`, runtime
|
||||
configuration is `Linux`, framework is `netcoreapp1.0`, runtime
|
||||
identifier is `ubuntu.14.04-x64`, and binary name is `powershell`. The
|
||||
function `Get-PSOutput` will return the path to the executable; thus
|
||||
you can execute the development copy via `& (Get-PSOutput)`.
|
||||
|
||||
Reference in New Issue
Block a user