1
This is not the same as this.
In my case I have a simple Cygwin installation. Up to now the prompt has been in a bold green colour (my name) followed by a bold yellow colour (location). The $ is bold on the next line.
I wanted to change the location of my Home directory so I changed cygwin.bat to this:
@echo off
SETLOCAL
set HOME=D:\My Documents\Software projects\Cygwin\Mike
D:
chdir D:\apps\cygwin64\bin
bash --login -i
Line 2 and 3 here have been added by me.
This works great: I've also added a shortcut to this .bat file to
C:\Users\Mike\AppData\Roaming\Microsoft\Windows\SendTo
so that I can start a terminal in any location from the Explorer context menu... and "cd ~" takes me to the above "HOME" location.
But my name (green) and the location (yellow) are now unbolded. Does anyone know what this means?
later
thanks to David Postill, following his answers:
in the (real) '~' directory:
$ grep -Irn 'PS1' --include="*profile*" 2> /dev/null
$ grep -Irn 'PS1' --include="*bash*" 2> /dev/null
Both of these returned nothing at all... from this I concluded that the default prompt was coming from somewhere else... and also surmised that in the new "remote" HOME directory I could then add a PS1 value to my .bashrc.
PS1="\[\033[1;32m\]\u@\h:\[\033[1;33m\]\w\n\[\033[0;37m\]\$ "
and I got a BOLD prompt. But I then realised that the problem was not that the prompt here had been "non-bold", it was that it had been "dim" (see here).
Great, I thought, do this:
PS1="\[\033[0;32m\]\u@\h:\[\033[0;33m\]\w\n\[\033[0;37m\]\$ "
... because 0 before the semicolon is meant to be "normal" (2 is meant to be "dim")... But the prompt then came out not normal... but dim again. Grrrrrr. I give up (temporarily!).
Thanks... in fact in that new location there are the same .bashrc, .bash_profile, .profile files. But, spurred on by your suggestion, I went to see if I could spot an uncommented line configuring the prompt ... I couldn't. Even if your idea had been 100% correct (you're probably on the right lines), you don't offer an explanation of why the non-bolding occurs, or what it means... – mike rodent – 2017-12-31T18:55:31.713
@mikerodent The non bolding can occur if your prompt is set incorrectly and/or your terminal emulator does not have bold enabled. See How to make the terminal display user@machine in bold letters?
– DavidPostill – 2017-12-31T19:05:01.677