Console2 and ConEmu - weird command line

Thank you for your help.

I am a happy user of Cygwin and Mintty on Windows 7. But I always like to see what other options are. So I downloaded Console2 and ConEmu.

The first step is always, runinng bash. It was easy. Just typing 'bash' ... In the second step, set up the look. It was impossible!

As you can see in the following screenshot, it looks like ANSI colors are not supported, which I can expect from Console2 form, but without ConEmu form. Console order (top to bottom): Mintty (Cygwin), Console2, and ConEmu.

enter image description here

So, any ideas on what is going on?

I loaded Console2 months ago, and I think the colors worked fine. I have no idea why it now looks like powershell.

I really tried Powershell a few weeks ago and changed the colors a bit. Could this cause a mess in other terminals?

Luckily for me, Mintty is fine.

Thanks!

UPDATE:

Looks like the problem is on my command line!

It works great in Mintty, but he doesn't like Console2 and ConEmu.

# Custom Shell # Green 113 # Red 173 # Blue 81 # Yellow 186 # Light Green 194 # Light Blue 195 function EXT_COLOR () { echo -ne "\e[38;5;$1m"; } function CLOSE_COLOR () { echo -ne '\e[m'; } PS1=' `EXT_COLOR 81`\]\ u@ \h`CLOSE_COLOR`\] `EXT_COLOR 195`\]$PWD >`CLOSE_COLOR`\]`EXT_COLOR 173`\]$(__git_ps1 " (%s)")`CLOSE_COLOR`\]\n ' export LS_COLORS='di=38;5;108:fi=00:*svn-commit.tmp=31:ln=38;5;116:ex=38;5;186' echo -e "\e[38;5;194m$(date +%A\ %d\ %B\ %Y\ -\ %H:%M)\e[m" 
+4
source share
1 answer

Regarding ConEmu

  • Run bash as a root process (also like a shell), why are you trying to use it from cmd with no arguments? The correct syntax is sh.exe --login -i .
  • if you want a special palette (for example, brown background) - adjust the palette (color page)

Your screenshot is of poor quality, the text cannot be read. But it looks like bash doesn't use ANSI colors (why? Afaik write colors directly to the console). So, you need to dig out the bash settings to enable tooltip coloring. Refer to the bash manuals or your settings, the TERM variable may be defined - I don't know.

Finally, ConEmu supports ANSI escape sequences, but

  • ConEmuHk.dll must be injected into the process (which uses Ansi), so bash must be the root process or the "Inject ConEmuHk" option must be enabled.
  • The Ansi X3.64 option should also be enabled.

I loaded Console2 months ago, and I think the colors worked fine. I don’t have a clue why now it looks like powershell.

Afaik, Console2 saves its palette in an xml file. And this is only one palette for all console applications running in Console2.

ConEmu can be customized to your taste. There is a main palette (the Colors page), and you can choose your own palettes for any console application running on ConEmu (a separate application page).

I really tried Powershell a few weeks ago and changed the colors a bit. Could this cause a mess in other terminals?

It looks like you configured the Powershell palette in Console2 (manually).

+4
source

Source: https://habr.com/ru/post/1439255/


All Articles