Note: This picture shows a different PS1 that includes git branch info and adds color
Last active
March 29, 2017 22:32
-
-
Save prestonp/64bd075503bccf9c6257 to your computer and use it in GitHub Desktop.
dynamic emoji shell 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
emoji() { | |
emojis=("π " "π© " "πΆ " "π£ " "π " "πͺ " "π³ ") | |
echo ${emojis[$RANDOM % ${#emojis[@]} ]} | |
} | |
set_bash_prompt() { | |
# Define your prompt formatting here | |
export PS1="\d \t \u:\w\n$(emoji) " | |
} | |
# Terminal prompt formatting | |
PROMPT_COMMAND=set_bash_prompt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment