From 326c2b08593e9b02da149dcc0d3c5cf99b21d3a2 Mon Sep 17 00:00:00 2001 From: Andy Bateman Date: Sun, 20 Sep 2015 08:46:45 +1200 Subject: [PATCH] Replaced the use of 'print' with 'echo' in order to sanitise track and artist names Fixed indentation Fixed indentation --- plugins/osx/osx.plugin.zsh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/osx/osx.plugin.zsh b/plugins/osx/osx.plugin.zsh index 9413f5056..86778363b 100644 --- a/plugins/osx/osx.plugin.zsh +++ b/plugins/osx/osx.plugin.zsh @@ -166,9 +166,9 @@ function itunes() { if [[ "$state" = "playing" ]]; then currenttrack=`osascript -e 'tell application "iTunes" to name of current track as string'` currentartist=`osascript -e 'tell application "iTunes" to artist of current track as string'` - print -P "Listening to %F{yellow}$currenttrack%f by %F{yellow}$currentartist%f"; + echo -E "Listening to $fg[yellow]$currenttrack$reset_color by $fg[yellow]$currentartist$reset_color"; else - print "iTunes is" $state; + echo "iTunes is" $state; fi return 0 ;;