Post History
How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command. Here's about how ...
Question
zsh
#2: Post edited
- How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command.
- Here's about how it should look like (just a very basic prompt for illustration):
- ```zsh
[me@pc ~]$ echo Have you tried StreetComplete? [10:24:07]- Have you tried StreetComplete?
- [me@pc ~]$
- ```
- Presumably something in `.zshrc` file should do the trick.
- How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command.
- Here's about how it should look like (just a very basic prompt for illustration):
- ```zsh
- [me@pc ~]$ echo Have you tried StreetComplete? [10:24:07]
- Have you tried StreetComplete?
- [me@pc ~]$
- ```
- Presumably something in `.zshrc` file should do the trick.
#1: Initial revision
Show a timestamp on the right side of prompt when executing a command in ZSH
How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command. Here's about how it should look like (just a very basic prompt for illustration): ```zsh [me@pc ~]$ echo Have you tried StreetComplete? [10:24:07] Have you tried StreetComplete? [me@pc ~]$ ``` Presumably something in `.zshrc` file should do the trick.