I lose too many columns in my terminal because of the credentials ( Victor-Rodriguess-MacBook-Pro:~ victorrodrigues$ ). Could I shrink this?
The only information I see as really needed sometimes for me is the folder name, nothing else.
What you're after is a custom bash prompt.
For just displaying the folder name, add this to your
This is what it will look like (your home directory is shortened to tilde):
[~]$cd / [/]$cd /usr/bin/ [/usr/bin]$
For an excellent overview and a list of the other available escape sequences, check out the following article: How to: Change / Setup bash custom prompt (PS1). It is a Linux tutorial but it works in bash on Mac as well.
|show 1 more comment|
As a general note:
The bash session started by Terminal.app is usually a login session. (You will see the difference as the login session will tell you about your last login on startup.) This can be changed in the preferences where you can choose between
Login sessions don’t usually execute the scripts in
To get consistency over login and non-login shells, one usually changes