I have now with the latest test tested PowerShell 7.3.0-preview.8 on wine-7.3-repack-1 on Ubuntu 22.10.
https://github.com/PowerShell/PowerShell/releases
PowerShell exists also native for Linux. But it make also sense, to run the Windows-Version on WINE.
On Windows the PowerShell replaced cmd.exe. And so it is the new command line interface.
The 64bit PowerShell don't run. It gives out the error
Code: Select all
0100:err:virtual:virtual_setup_exception stack overflow 1808 bytes in thread 0100 addr 0x170054794 stack 0x208f0 (0x20000-0x21000-0x1a0000)
It gives out some error messages, but it works.
If I run it with wineconsole, there existing the problem, that wineconsole can't handle ANSI escape codes. And so there is no nice coloring but a lot of printed esape codes.
But in the GNOME Terminal with wine started, it works better.
Commands like
Code: Select all
Get-ChildItem
Code: Select all
Get-Process
Code: Select all
Get-ChildItem *.exe | select Name
But if I input it, the typed input text, jumps to the beginning of the line or the next line and so on. Input a command is very problematical.
But if the command or script is input, then the command or script runs perfect.
Also small scripts, which makes use of the Windows Forms, are working. Like open a MessageBox:
Code: Select all
Add-Type -AssemblyName PresentationFramework
[System.Windows.MessageBox]::Show('Hello World')
Code: Select all
Add-Type -AssemblyName System.Windows.Forms
$form = [System.Windows.Forms.Form]::new()
for($i = 10; $i -lt 100; $i += 20) {
$chkbox = [System.Windows.Forms.CheckBox]@{
Location = [System.Drawing.Point]::new($i, 10)
Size = [System.Drawing.Size]::new(20, 20)
}
$form.Controls.Add($chkbox)
}
$btn = [System.Windows.Forms.Button]@{
Location = [System.Drawing.Point]::new(80, 80)
Text = 'Select All'
}
$btn.Add_Click({
foreach($control in $form.Controls) {
if($control -is [System.Windows.Forms.CheckBox]) {
$control.Checked = $true
}
}
})
$form.Controls.Add($btn)
[System.Windows.Forms.Application]::EnableVisualStyles()
$form.ShowDialog()
The Out-GridView creates and error.
Code: Select all
Get-ChildItem | Out-GridView
Code: Select all
Get-Process | Out-GridView
Same with the graphical help:
Code: Select all
Show-Command
So I would be happy, if the 64bit PowerShell of WINE works. And there isn't a problem to type a input there. Also I would be happy if the Out-GridView and Show-Command works.
I am the only one, who uses the PowerShell on WINE?
With the WSL Microsoft uses also the native Linux bash on Windows, because it have some advantages and it makes sense.
I think it is similar with the native Windows PowerSehell on Linux.