Add file/dir count to prompt and short prompt

This commit is contained in:
Talia 2018-12-23 21:23:00 +01:00
parent 0c7f600d01
commit 056b91da1d

7
bashrc
View file

@ -107,5 +107,10 @@ git__prompt () {
fi fi
} }
PS1='\[\033[00;34m\]┌─╼ \[\033[00;33m\]\$ \[\033[01;35m\]\u\[\033[00;34m\]@\[\033[01;35m\]\h\[\033[01;34m\] `date +%d.%m.%y` \[\033[01;35m\]\w`git__prompt`\[\033[00m\] PS1n='\[\033[00;34m\]┌─╼ \[\033[01;34m\]`date +%d.%m.%y` \[\033[00;33m\]\$ \[\033[01;35m\]\u\[\033[00;34m\]@\[\033[01;35m\]\h`git__prompt` \[\033[01;35m\]\w \[\033[01;34m\]`find -maxdepth 1 -type d | wc -l`\[\033[00;34m\]d \[\033[01;32m\]`find -maxdepth 1 -type f | wc -l`\[\033[00;32m\]f\[\033[00m\]
\[\033[00;34m\]└╼ \[\033[00m\]' \[\033[00;34m\]└╼ \[\033[00m\]'
PS1c='\[\033[00;34m\]┌─╼ \[\033[00;33m\]\$ \[\033[01;35m\]\u`git__prompt` \[\033[01;35m\]`basename \`dirs +0\`` \[\033[01;34m\]`find -maxdepth 1 -type d | wc -l`\[\033[00;34m\]d \[\033[01;32m\]`find -maxdepth 1 -type f | wc -l`\[\033[00;32m\]f\[\033[00m\]
\[\033[00;34m\]└╼ \[\033[00m\]'
PS1=$PS1n