Change Cygwin Prompt

cygwin;

The default cygwin prompt of "user@computer path \n $" is too long for me. I would like to keep the path.

I want it to become:

path $

Is there a config file I can modify to do this?

Best Answer

The PS1 environment variable controls the prompt:

PS1='\w $ '

For more information on this and other prompt configuration topics, type man bash (assuming bash is your shell) and see the "PROMPTING" section.

To make this change permanent, edit your ~/.bashrc file to add the above line.

Related Question