Skip to content

Commit

Permalink
Merge pull request #2661 from mcornella/fix_title_tab_percent
Browse files Browse the repository at this point in the history
Fix escaping of $CMD of automatic title
  • Loading branch information
robbyrussell committed Mar 28, 2014
2 parents ae0c650 + 5137e0e commit 175310a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/termsupport.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,11 @@ function omz_termsupport_precmd {
function omz_termsupport_preexec {
emulate -L zsh
setopt extended_glob
local CMD=${1[(wr)^(*=*|sudo|ssh|rake|-*)]} #cmd name only, or if this is sudo or ssh, the next cmd

# cmd name only, or if this is sudo or ssh, the next cmd
local CMD=${1[(wr)^(*=*|sudo|ssh|rake|-*)]:gs/%/%%}
local LINE="${2:gs/%/%%}"

title '$CMD' '%100>...>$LINE%<<'
}

Expand Down

0 comments on commit 175310a

Please sign in to comment.