Last active
January 9, 2022 23:05
-
-
Save Lemmings19/e2b7fb761ab9af066814eb5315d63542 to your computer and use it in GitHub Desktop.
Working Linux Terminal Prompt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Example Prompt using this gist: | |
# 2022-01-09 23:00:50 user@host: ~/my-folder $ | |
# Sets the scheme for the terminal prompt. Note that '##m' constitutes a colour code. | |
# Avoids several bugs, including the terminal input line-wrapping over the prompt. | |
# Includes the full date and time. | |
# In Ubuntu, add this to '~/.bashrc', then run 'source ~/.bashrc' and start a new terminal | |
# to apply the new prompt. | |
PS1='\D{%F %T} \[\033[01;32m\]\u\[\033[00m\]@\[\033[01;36m\]\h\[\033[00m\]: \[\033[01;34m\]\w\[\033[00m\] $ ' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Available colour codes:
00m
30m
31m
32m
33m
34m
35m
36m
37m