- changed status to resolved
Self Contained PowerShell 7 Scripts?
I know this works in Powershell Core 6, does it also work in Powershell 7 (PS v7.0.0-preview.1)?
I’m getting
Merge-Script : You need to install .NET Core SDK to use packaging. You can download it from Microsoft. https://dotnet.microsoft.com/download
At line:1 char:2
Merge-Script -Config @{
CategoryInfo : InvalidOperation: (:) [Merge-Script], Exception
FullyQualifiedErrorId : PowerShellToolsPro.Cmdlets.MergeScriptCommand
I’ve installed
- .NET Core 2.2 SDK
- Microsoft .NET Framework 4.6.2 Developer Pack
- .NET Core 3.0 SDK (3.0.100-preview6-012264)
This makes and EXE, but I think it runs in PS5
Merge-Script -Script .\script.ps1 -Output .\ -Package
This gives the above error
Merge-Script -Config @{
Root = ".\script.ps1"
OutputPath = ".\"
Package = @{
Enabled = $true
PowerShellCore = $true
}
Bundle = @{
Enabled = $true
Modules = $true
}
}
I might just be doing something wrong and this isn’t an issue, if so sorry
Requested info
VS code 1.35.1
PowerShell Pro Tools 4.6.1
PS C:\> $PSVersionTable
Name Value
PSVersion 7.0.0-preview.1
PSEdition Core
GitCommitId 7.0.0-preview.1
OS Microsoft Windows 10.0.18362
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
Comments (1)
-
- Log in to comment
Added in 4.8.2