Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Adds random emoji to your terminal prompt on Mac OS X, because emoji.
# Add this file to your home directory then include it in ~/.profile using `. ~/.profile-emoji-me.sh`
# These will show up in an emoji compatible terminal
ME_EMOJI=(🐶 🐱 🐭 🐹 🐰 🦊 🐻 🐼 🐨 🐯 🦁 🐮 🐷 🐸 🐵 🐙);
RANDOM_ME_EMOJI=${ME_EMOJI[$((RANDOM%14))]};
export PS1="\h:\W \u $RANDOM_ME_EMOJI ";
export PROMPT_COMMAND='update_terminal_cwd; echo -ne "\033]0;${RANDOM_ME_EMOJI##*/}\007"';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment