Created
July 8, 2019 17:20
-
-
Save ravicious/94f941a50f927262db8cdb494068f0a5 to your computer and use it in GitHub Desktop.
Time in ZSH 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
RPROMPT="%{$fg[white]%}[%*]%{$reset_color%}" | |
# Reset the prompt before accepting the line. | |
# https://stackoverflow.com/a/35051172 | |
function _reset-prompt-and-accept-line { | |
zle reset-prompt | |
zle .accept-line # Note the . meaning the built-in accept-line. | |
} | |
zle -N accept-line _reset-prompt-and-accept-line |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment