p="${${SSH_CLIENT+$s}:-$p}"
local clock="%F{$n}%T%f" dirvcs="%F{$d}"'${vcs_info_msg_0_:-%~}'"%f"
+ # XXX: linux only
local battery=/sys/class/power_supply/BAT0/capacity
[[ -e "$battery" ]] && clock+=" `cat $battery`%%"
local vicol='%F{${${prompt_arrows_vimode:+'"$r"'}:-'"$c"'}}'
+ local hist="%F{$n}%h"
case "$m" {
2line)
- PROMPT="%f $clock $dirvcs"$'\n'"%F{$c}>>> "
+ PROMPT="%f $hist $clock $dirvcs"$'\n'"%F{$c}>>> "
unset RPROMPT
;;
right)
RPROMPT="$dirvcs $clock"
- PROMPT="%F{$c}>>> "
+ PROMPT="%F{$c}>>> $hist"
;;
*)
echo "Unknown prompt mode $m"
## jobs
setopt AUTO_CONTINUE
## history
-setopt NO_HIST_SAVE_BY_COPY HIST_IGNORE_DUPS SHARE_HISTORY
+setopt NO_HIST_SAVE_BY_COPY HIST_IGNORE_DUPS SHARE_HISTORY HIST_REDUCE_BLANKS
### keys
# TODO: investigate "^[[200~" bracketed-paste