Hacker News new | past | comments | ask | show | jobs | submit login
Windows Terminal Quake Mode (github.com/microsoft)
182 points by ingve on May 2, 2021 | hide | past | favorite | 88 comments



Disregarding the geek and nostalgia factor. Why is this a feature of a specific application and not the WM?

In fact it's almost already there. Just put your terminal as first item in the task list, then press Win+1 to summon a terminal and then Win+1 again to hide it. All existing window location and focus rules stay the same. What's missing?


> Why is this a feature of a specific application and not the WM?

Presumably because it's quicker or easier to implement this at the application layer rather than at the WM layer. Also, it makes the functionality available no matter which WM one is using, including ones that don't support this natively.


Had no idea this existed. Haven’t seriously used windows (except to ssh into my Linux machines) in over a decade, though.


Had been literally doing this first as a "poor man's" quake mode since moving away from ConEmu - pretty soon realised it was just enough for me. So I'd rather they find an elegant solution to UAC elevation.


Very curious as to why you moved away from ConEmu. Can you share the motivating factors? Anything to be concerned about?


It just never really worked well for me in a multi-monitor setup with two screens and a docking station... Now, Windows itself is quite terrible with this and often moves windows between screens for no reason. For example, when primary screen takes a second longer to come back from sleep, all windows float to secondary one, at least that is what I guess is happening.

Now, with ConEmu, that also caused some rendering defects and I would have to hide/show window and sometimes reopen tabs to get it to work again. If I understand correctly, ConEmu does some sort of off screen rendering hack with conhost and then just synchronizes the bitmap to where its real window is. Though I may be completely wrong and that is not how it really works. But these issues have never occurred with WT.

Otherwise, I had nothing to complain about with ConEmu, especially its UAC handling is awesome. Unless we could have proper sudo on Windows, of course. That would be even better UX :)


I'm not the grandparent poster, but I notice ConEmu sometimes display my Linux terminal (connected via Cygwin's SSH) strangely after being resized, I would try to edit a file in Joe and trying to navigate would just update the 1st line of the console. I could scroll down in a less window but going up garbled the display...


> Many existing terminals support a feature whereby a user can press a keybinding anywhere in the OS, and summon their terminal application. [...] This global summon action is often referred to as "quake mode", a reference to the video game Quake, who's console slid in from the top.

This is not to play Quake in WT, this allows WT to behave like the console window in Quake descendants that displays when [ ~] is pressed, the console whose sole purpose is to accept `sv_cheats 1` command (jk). For me it was `setenv therewasacow 1337` if my memory serves well...


Hey now, I've used it to blindly type in the command to switch screen resolution when I accidentally set it to something my computer didn't support back in the day


This reminds me of using a floppy disk and a bunch of blind keyboard commands to recover my corrupted BIOS in 2002. Felt like a wizard when it worked.


That does sound helpful. Although, in Quake, you can shoot the monstrosities that vex you. You cannot do that in Windows.


Looks like we need a quake/windows version of this doom/Linux tool: https://www.cs.unm.edu/~dlchao/flake/doom/


for callofduy it was `seta thereisacow 1337` you could do just set but seta = archive = persistent


> This is not to play Quake in WT, this allows WT to behave like the console window in Quake descendants that displays when [ ~] is pressed

That's what they're saying.


Is someone having reading comprehension issues?


Is someone?


The friendly article linked says:

> Many existing terminals support a feature whereby a user can press a keybinding anywhere in the OS, and summon their terminal application. [...] This global summon action is often referred to as "quake mode", a reference to the video game Quake, who's console slid in from the top.

The commenter I replied to said:

> This is not to play Quake in WT, this allows WT to behave like the console window in Quake descendants that displays when [ ~] is pressed.

The original article said nothing of the sort, even the part he quoted contradicted him, it was obvious that whoever wrote about this feature knew what "Quake mode" meant.

Then someone downvoted me for pointing that out.

Reading comprehension fail x2 ¯\_(ツ)_/¯

> Is someone?

Is anyone, really?


I've been using Auto Hotkey[1] for a while and it's truly amazing to bring the missing hotkeys feature to Windows.

This, plus Altdrag[2], Quicklook[3] and Winxcorners[4] are my must have.

1: https://www.autohotkey.com/

2: https://stefansundin.github.io/altdrag/

3: https://www.microsoft.com/en-us/p/quicklook/9nv4bs3l1h4s

4: https://github.com/vhanla/winxcorners


I played with Auto Hotkey (AHK) recently as I wanted to add a layer to my keyboard. Wow, what powerful software! But I really disliked the scripting language and wished they'd used a standard language.

I ended up installing TouchCursor [1] which did everything I need at present, but will persevere with AHK.

1: http://martin-stone.github.io/touchcursor/


I totally agree with the pain of their scripting language.

Here is mine, it's very basic but does the few things I wanted (i.e run a program with a combination of keys): https://gist.github.com/tbronchain/c52b610a76eac8c26faae9ad2...


Look at AutoIt. It's a more traditional basic language, and iirc AHK was a fork of a very early version a few decades ago.


Yeah, AHK is amazing and worth learning, but its scripting language is astonishingly awful.


AltDrag has been one of the first pieces of software I install on a Windows machine for years now. Such a time saver.

As we're a little OT here, I might as well recommend you check out GridMove which moves windows to predefined positions on any of the screens with a press of a hotkey.


alt drag is something I picked up on Linux. I was delighted to find it for Windows several years ago, and the name made it really easy to find.

Mac window management continues to infuriate me.


I can not recommend Contexts [1] and Rectangle [2] enough!

[1]: https://contexts.co/ [2]: https://rectangleapp.com/


Auto Hotkey is surprisingly powerful

Here's Tom Scott talking about how he used AHK and Lua to make a keyboard for every emoji

https://www.youtube.com/watch?v=lIFE7h3m40U


I am using iTerm2 just for this feature. Otherwise I'd use Alacritty

Also It is pretty good to see Windows Terminal finally gets usable features.

A POSIX compatible shell would be nice...


See my [Phoenix config](https://github.com/NightMachinary/.shells/blob/master/.phoen...) (or Phoenix's docs) to create hotkey windows for any apps. I have been using this with Kitty, and it works very well, unless you want to have multiple windows.


Is shell by itself valuable at all without the surrounding toolchain?


I use ConEmu on windows with PuTTY, PowerShell and CMD attach3ed as consoles to have exactly this. In fact the ConEmu setting is called "Quake mode" ~ drop down. I do all my work from my replacable windows box, and code exclusively in vim ssh'ing into whatever VPS.

So I can be viewing the website in a browser on windows, then Ctrl+~ to get my shell/vim screen, type some code, the server restarts and I can reload. Fast feedback loop. I love it!


I really like that this is documented. huge respect for that.

this could just be some gimmick thrown in. taking the time to give this capability some context, done definition, it feels real good. it makes it culturally enduring.

this is spec #653, an early-ish idea. but it cites & builds atop spec #5000, process model 2.0, which specifically cites quake mode as a capability the new process model enables (and also tab tearing away). this isanifestation of WT turning into a mini/macro/alt offering to tmux, a way of making terminals quasi independent entities.


It's not a gimmick. It's something supported by the leading terminal emulators on pretty much every other desktop environment for the last 10 years and it's a massive productivity boost for people working on single screens (like a laptop).

I agree that the level of documentation for this feature is really quite impressive though. It shows that they're investing time to do this properly rather than rushing through some half baked feature out of fear of playing catch up.


The specs are great and i agree that having one for the more complicated features is a great benefit.

I have seen specs in another project where pseudocode was also used, but am beginning to think that often leads to a poor code quality.

Note that Windows Terminal project uses issue numbers for specs, so there are not 5000 specs :)

https://github.com/microsoft/terminal/tree/main/doc/specs

Another file worth looking at from time to time is the Roadmap.

https://github.com/microsoft/terminal/blob/main/doc/terminal...


Being a user of Cmder (ConEmu), I have been waiting for this for a long time. Thank you to OP for naking me aware that this is now available


ConEmu manages the whole elevated/non-elevated situation better than Windows Terminal in my opinion.

As mentioned in the article elevated and non-elevated Windows Terminal windows are two different apps. In ConEmu they are tabs in the app.

The real benefit is that you can easily start either a elevated or non-elevated window within ConEmu, of course this is only possible if ConEmu was started in elevated mode in the first place.


In Windows Terminal, I'm sure you can create a new profile with your chosen shell prepended with "start-process -Verb RunAs" that will offer similar fuctionality.


And it seems some improvements to mixed elevation is coming soon:

https://github.com/microsoft/terminal/pull/8455


Only small improvements; that report specifically says that the full feature isn't possible:

> For a long time, we've been researching adding support to the Windows Terminal for running both unelevated and elevated (admin) tabs side-by-side, in the same window. However, after much research, we've determined that there isn't a safe way to do this without opening the Terminal up as a potential escalation-of-privilege vector.


It still opens a separate window, unfortunately.


I use the gsudo program for that gives you sudo in windows terminal and just elevates current shell.


Its not quite available yet, looks to be getting the bulk of the work released in 1.9 looking at https://github.com/microsoft/terminal/issues/8888


For the impatient, there's a community built companion program for Windows Terminal that enables Quake Mode drop down until it is officially implemented[0].

[0] https://github.com/flyingpie/windows-terminal-quake


Been using this type of style on iTerm2 for a while.

iTerm is so good I’d happily pay for it.

Edit: just found they have a donate page, donated.


Only for the record/memory, an old tool that was (is) very nice:

https://sourceforge.net/projects/winqconsole/


Been waiting for this for ages, I hope it comes fast!


Please come up with reverse searches and forward searches in terminal and I swear I will change my primary OS to Windows.


PowerShell has shipped with PSReadLine since version 6.


I highly recommend using tmux. It works well with the MS terminal (and other terminals).

You'll get forward and reverse searching, split panes, windows (similar to tabs), excellent window and pane management binds (moving them, switching orders, zooming in / out, etc.), persisted sessions that you can save and restore across reboots and good mouse support if you want it.

The best part is it works the same with every terminal so you can super charge any terminal and use the same tmux configuration in multiple environments. This way you can make a terminal choice based on optimizing for speed, low key press latency and other traits that make a terminal feel nice to use.

I gave a command line talk once that focuses on using tmux, Vim and various Unix tools at https://github.com/nickjj/nyhackr-cli-dev-env. The slides and video links are listed there. The videos all have timestamps so you can jump around to the tmux bits pretty easily.


Reverse/forward searches are features of the shell, not the terminal. As others have noted, PowerShell supports those.


> searches are features of the shell, not the terminal

no, tmux/screen implement search in the terminal output buffer and work well.


Do they, though? They have their own buffer.


tmux supports this.


Tmux is not a terminal, though.


I’ve been using Ctrl+Shift+f in Windows Terminal for this (it searches terminal output/its scroll back buffer).


It's not the same: reverse/forward searches look into command history to let you relaunch commands prevously used.


Clink [https://mridgers.github.io/clink/] adds this functionality and much more to good old fashioned command prompt (which I prefer to powershell because it's much faster and simpler)


That repo is extremely outdated. Here's the official(?) supercharged fork, which is actively developed - https://github.com/chrisant996/clink


Huh, I did wonder if there was an updated fork but I obviously didn't look hard enough. Thanks!


https://mridgers.github.io/clink/ gives you readline editing in cmd.exe


Terminal features would be a footnote in the 1400 page book containing list of things I'd like to see in Windows :-)


And a 1000 of those are bugs that have been around since Windows 98.


Any example?


One simple one: If I start multiple Kopies/file downloads, Windows will run them all in parallel, even if they run through the same connection. So if after 50% there´s a connection drop, all of them will abort. This used to be especially bad on nicely defragmented disks, because the extra seeking makes parallel copies slower then sequential ones.

Even after all this time, they can`t figure out to automatically chain I/O operations (or at least give me some UI to do it explicitly).


Fuzzy history search like fzf does is in my experience quicker. And also works in Powershell.


Are you using PSFzf or something else? https://github.com/kelleyma49/PSFzf


I used to use PSFzf indeed: it's pretty good and got me started with fzf on PS, but the history reading nor file scanning are particularly fast so currently I'm using some C# code to do those and pipe it into fzf directly. Don't recall exactly but the most basic C# code I could come up with which does 'read history file in reverse and skip duplicates' was like 3 times faster than what PSFzf uses.


By reverse search do you mean this [link redacted] because you can do that with Ctrl-R now :)


Now do tiling wm and package manager (with easy source builds from recipes) and it'll start to become a decent OS.


They do have an official not-quite tiling VM: FancyZones[1]. I don't know how good it is, but it's open source. I personally use AquaSnap [2] (commercial, 18 USD) for my window tiling & snapping needs which has definitely been a worthy purchase.

[1] https://docs.microsoft.com/en-us/windows/powertoys/fancyzone...

[2] https://www.nurgo-software.com/products/aquasnap


I have been using FancyZones for about a year. It's not quite a twm, it allows you to redefine the snap zones but they are fixed/static. There's also very little in the way of shortcuts to control them.


Apparently they’re working on an official package manager, open source even:

https://github.com/microsoft/winget-cli/


The state of this new package manager called WinGet was recently discussed here:

https://news.ycombinator.com/item?id=26845530


...and of course provide an easy way to turn off all the spyware.


Have you seen choclatey?


I love choco and use it heavily. The only thing I'm really missing on Windows coming from Linux is a update commandline utility like apt where I can see all updates and can install them one by one if I want to


choco outdated


I use Guake as my preferred terminal on Linux for this reason. I love how I can just pull it up over everything and put it away with one key press.


I used to use Guake but felt the need sometimes to be able to resize/move terminal open next to a window, say, for comparing something. So I instead setup a script to run a regular terminal such that it a) starts a terminal instance if none are running b) activates the terminal window if an instance is running and c) presses alt-tab to switch away from terminal if the terminal window is active. The script is bound to a shortcut key so basically I get the Guake type functionality (without the fancy drop-down of course) + can treat the terminal as just another window on the desktop.


Can you share the script please? It sounds like something I'd find very useful



I <3 this


cmd.exe —nowait


Linux and macOS terminals have had this for years. At least a full decade.


Sure, but it's nice that Windows is coming along in terms of developer-friendliness.


If you want developer friendliness, try Linux or BSD.

Full source and debugging symbols for mostly everything. Everything can be tinkered with with no limits.

Windows will never be like this. If you want to understand how things work there will be a limit where you will have to become a reverse engineer to do it. With Linux this is not the case.


Your argument kind of makes me think of Proton and the massive efforts of Wine, Valve, DXVK, and other projects that have increasingly made Linux a more attractive platform for gaming. You could argue that Linux will 'never be good enough' and if you want to play games you should just 'try Windows.'

I think it's worth celebrating the efforts and the progress that has been made on Linux towards being a better platform for gamers. Is it perfect? Nope! Considering the market develops with Windows in mind, you're a lot less likely to run into issues running games on Windows, but it's definitely better than it was a few years ago.

Similarly, I think that Microsoft's efforts to make Windows a better platform for developers should be welcomed! I don't think Windows is as good a platform for a lot of developers as Linux/BSD and it may never be, but the progress in that regard is praise worthy, I think.


Alternatively, you can buy a console. It's cheaper than a desktop PC.

I have many games on Steam that I can run on Linux but I hardly ever play. I don't have much time for that.


fully expecting Blue Screen




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: