[zsh] Print date and system info on prompt start
This commit is contained in:
parent
f697e616d3
commit
087ad33d2e
1 changed files with 13 additions and 2 deletions
15
zprofile
15
zprofile
|
@ -1,6 +1,7 @@
|
|||
#!/usr/bin/env zsh
|
||||
# Eryn Wells <eryn@erynwells.me>
|
||||
|
||||
|
||||
# Start SSH agent for password-less logins
|
||||
if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]; then
|
||||
if ! pgrep -u $USER ssh-agent 1>/dev/null; then
|
||||
|
@ -11,6 +12,16 @@ if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]; then
|
|||
fi
|
||||
fi
|
||||
|
||||
autoload list_tmux_sessions
|
||||
list_tmux_sessions
|
||||
autoload -Uz list_tmux_sessions
|
||||
autoload -Uz binary_exists
|
||||
|
||||
if binary_exists sw_vers && binary_exists lolcat; then
|
||||
case $SYS in
|
||||
darwin)
|
||||
print "It's `date +'%H:%M on %A, %B %d'`.\nThis machine is a $HWMODEL.\nYou're running macOS $OSVERSION.\n" | lolcat
|
||||
;;
|
||||
*) ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
list_tmux_sessions
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue