To get an Ubuntu-like prompt (assuming bash is installed):
- Edit the .bashrc file with an editor like vi
- Add this as the last line: export PS1='\u@\h:\w$ '
- \! History number of current command
- \# Command number of current command
- \d Current date
- \h Host name
- \n Newline
- \s Shell name
- \t Current time
- \u User name
- \W Current working directory
- \w Current working directory (full path)
Use set -o emacs (the default) or set -o vi to set your command line editing mode of choice.
And remember kids, don't forget to write the other users if on a public machine! (Or maybe talk, or wall if you're the admin).
More links
- Prompt Magic
- The 256 Color Mode of xterm
- The exhaustive Bash Prompt HOWTO
No comments:
Post a Comment