code_fodder code_fodder - 1 year ago 128
Bash Question

In ConEmu is it possible to get the command prompt all in one line?

Just started using conemu on windows again (after quite some time using other rubbish). Its great, but there is one element that really bugs me, that is the command prompt is always spread over two lines: D:\user\workspace\
> D:\user\workspace\
> D:\user\workspace\

Can I get it so that this is compressed onto the same line, like this? D:\user\workspace\> D:\user\workspace\> D:\user\workspace\>

I looked through the settings and did not spot anything obvious.

I saw this question: link, but I think I want to do the opposite and I can't find where anything like
is defined in the settings...


In addition to the answer of Max, here is what I really needed to change in the CmdInit.cmd file:

rem Carriage return and `$` or `>`
rem Spare `$E[90m` was specially added because of GitShowBranch.cmd
if "%ConEmuIsAdmin%" == "ADMIN" (
set ConEmuPrompt2=$S$E[90m$$
) else (
set ConEmuPrompt2=$S$E[90m$G

Where both ConEmuPrompt2 where:

changed here ^

Answer Source
  1. Make a copy of ConEmu\CmdInit.cmd file.
  2. Replace I the copied file $_ with $S, save changes )
  3. Utilize your modified file in the task {Shells::cmd}.
  4. Save ConEmu settings.
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download