My freebsd terminal always only show "#" I want it show current directory. How can I manage that? Thank you indeed!

link|improve this question

That's because you're logged in as root. – Rafe Kettler Dec 24 '10 at 6:24
Check here for all the shell customization information you can stand: geekvenue.net/chucktips/jason/chuck/1039988302/index_html – Cody Gray Dec 24 '10 at 6:29
type pwd (print working directory) for quick look – Eric Fortis Dec 24 '10 at 6:30
feedback

migrated from stackoverflow.com Dec 24 '10 at 16:10

This question came from our site for professional and enthusiast programmers.

1 Answer

up vote 2 down vote accepted

if using bash shell - in .bash_profile add:

PS1="[\u@\h:\w] " 
case `id -u` in
      0) PS1="${PS1}# ";;
      *) PS1="${PS1}$ ";;
esac
link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.