Linux Bash Prompt

Here is my bash prompt, with the following features:

  • Red ✘ if the previous command has failed, otherwise a green ✔.
  • Shows running time of the previous command
  • Separate line for path and command

Example

screenshot_2016-11-07_06-24-23

Installation

Add this to your .bashrc:

Updates

  • 2017-04-28: Now prints days, hours, minutes, seconds. Much better readable for long running tasks.
  • 2016-11-04: Initial version

Sources

2 Comments on "Linux Bash Prompt"

Notify of
avatar
Thomas Einwaller
Guest

Coole Sache, muss ich mir mal anschauen wie ich das in meine zsh reinbekomm 😉

trackback

[…] my Linux Bash Prompt post. It’s […]

wpDiscuz