terminal icon indicating copy to clipboard operation
terminal copied to clipboard

Allow conhost to be replaced with OpenConsole

Open lhecker opened this issue 1 year ago • 3 comments

Description of the new feature/enhancement

conhost can lack behind OpenConsole by several (if not many) years. This brings 2 problems:

  • People preferring conhost's look and feel cannot get updates for many years.
  • We (the maintainers) cannot test new features and changes for many years.

In other words, not being able to replace conhost is a lose-lose situation.

Proposed technical implementation details (optional)

  • Ship a conhost package in the store that replaces the system conhost, just like how notepad does it.
  • Consider doing the same for the Windows Terminal Canary package so that we can get a slightly better usage coverage.

lhecker avatar Oct 14 '24 11:10 lhecker

So you are planning to use App Execution Alias for conhost.exe?

I tried that adding a registry entry: [HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\conhost.exe] @="I:\OpenConsole.exe" "Path"="I:\"

but I think there is something else needed to test it properly (without overwriting the original conhost.exe)

@lhecker any clue so I can test it?

The registry entry works if I call conhost.exe bash.exe from start/run, But it does not if in start/run I just type: bash.exe

I also tried: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths

But I get the same behaviour.

0wwafa avatar Oct 17 '24 15:10 0wwafa

C O N H O S T C O A S T T O C O A S T

zadjii-msft avatar Oct 17 '24 20:10 zadjii-msft

So you are planning to use App Execution Alias for conhost.exe?

That was the initial idea, but if it turns out to not work due to some platform limitation, then we'll have to modify the OS or use some other way to deploy it. The fact that it doesn't work for you seems to indicate that. I've also tried it, and it doesn't work for me either.

Edit: The solution is that we need to expose the name from a package. Modifying the registry like that only sets an alias for the shell / ShellExecute, e.g. like the Run dialog.

lhecker avatar Oct 18 '24 19:10 lhecker