You are not logged in.
Hi
I have a custom colored bash that when I open it shows like this:
user@machine:~]$then when I go to the Download folder it shows like this:
user@machine:Download]$and then again when I go to a Download subdir it shows like this:
user@machine:subdir]$is there a way to always view the entire path?
I mean:
user@machine:/home/user]$ cd Download
user@machine:/home/user/Download]$ cd subdir
user@machine:/home/user/Download/subdir]$ Thanks in advance
EDIT: Solution
I added this new line on my .bashrc, just before the line of "export PS1=..."
export GIT_PS1_PROMPT_DIRTRIM=4the "4" is the number of directory levels to show
and modified the "\W" with "\w"
Last edited by doomguy84 (2022-04-22 08:33:45)
Offline
Offline
thanks but...
I read it all, and the only thing I found was a "PROMPT_DIRTRIM" option to put into .bashrc, but it doesn't work
I believe it's my fault, but I can't figure out what is the problem
Offline
Try https://bashrcgenerator.com/. There are many PS1 generators, I find them very helpful as a learning tool, because the syntax isn't trivial.
Offline
I found my fault!!
I was using \W instead of \w
now it show the full path!!
thanks!
also thanks to Awebb, i will look that nice
Offline