Open htcfreek opened 1 year ago
Sorry could you elaborate more/? What exactly do you mean by "keep open"? Like, "always on top"? Or do you mean something more like "keep running even after I've closed all windows"? Or something else entirely? I'm not sure I'm totally familiar with all the powertoys these days 😝
@zadjii-msft
What I mean is a wt.exe parameter like cmd /k
or powershell -NoExit
that works on all profiles regardless off the profile/shell.
Use case: Shell plugin of PT Run. The window should stay open to show the results. (Currently we need some tricks to keep the command results visible which lead to https://github.com/microsoft/PowerToys/issues/28876.)
Oh, so like, a wt
command-line version of "closeOnExit":"never"
?
Oh, so like, a
wt
command-line version of"closeOnExit":"never"
?
yes
Er, well, reading that closer, that might not be quite right. -NoExit
isn't just "leave the window open after the command completes", it's "Return to the shell prompt after the command exits". I'm pretty confident that can't be done in a general-purpose way.
Like, for cmd.exe
, that would be cmd.exe /k {{command}}
, sure. But what if the user's commandline is set to ssh
? What if it's just ping.exe 8.8.8.8
? wsl.exe tmux -a
?
If the goal is just to leave the output on the screen after the command exits, that's easy enough to add with --closeOnExit=never
or whatever. But returning to the shell is probably impossible, without manually setting the commandline to something like cmd.exe /c {command} & {shell}
(which I'm sure is fraught with string excaping nightmares and other edge cases).
The main goal is to keep the window open for reading the output. So --closeOnExit=nerver
or even much easier --keepWindowOpen
is what we need.
@zadjii-msft I would like to work on this. But for the next three weeks I have no time. So if you feel this is important, please tell me and assign it to someone else.
Regarding the dev env: How many disk space do I need? Are there any special requirements I need to take care on?
Go for it! We're probably not going to get to this soon anyways.
RE: system reqs: Building cppwinrt code takes a lot of disk space for pch
files. Last I checked, it was on the order of 20GB. I know that's a lot 😕 Otherwise, I'm pretty sure https://github.com/microsoft/terminal#prerequisites covers the rest
@zadjii-msft You can assign me.
Then I think 60 - 80 GB should be enough free disk space hopefully.
@zadjii-msft
@davidegiacometti, I know that you have contributed code to WT in the past. Do you have an idea what is wrong/missing?
Do you have the old .NET Framework SDK installed?
WindowsTerminal.UIA.Tests
project targets .NET Framework 4.8
Do you have the old .NET Framework SDK installed?
WindowsTerminal.UIA.Tests
project targets .NET Framework 4.8
Do I need to install it in VS using the VS installer or can I download and install the sdk?
I tried to install the .Net 4.8 target release package on weekends without fixing the VS warning.
I have the .NET 4.8 installed from VS
@davidegiacometti , @zadjii-msft I got it building and created my first WT PR. 🤩 I left some comments in the PR about not working things and some questions.
Description of the new feature/enhancement
You can sett e keep open parameter as parameter of the shell used. But if this Is dynamic (e.g. in PowerToys shell plugin) a global parameter for WT would be helpful.
This parameter should keeps the WT window open regardless of the choosen profile and its parameters.
Proposed technical implementation details (optional)