lib/agile_notifier/tts.rb in agile_notifier-3.0.1 vs lib/agile_notifier/tts.rb in agile_notifier-3.0.2
- old
+ new
@@ -86,11 +86,11 @@
def speak_on_windows(text, language, voice = nil)
raise(NotImplementedError, "Method [#{__method__}] is empty, please implement", caller)
end
def osx_speech(voice, text)
- system("say -v #{voice} #{text} > /dev/null 2>&1")
+ system("say -v #{voice} '#{text}' > /dev/null 2>&1")
end
def tts_api(text)
url = 'http://tts-api.com/tts.mp3?q='
play(url + encode_www_form_and_remove_punctuation(text))
@@ -107,6 +107,6 @@
private_class_method :download_file, :remove_file, :play, :replace_punctuation_by_space, :encode_www_form, :encode_www_form_and_remove_punctuation, :osx_speech
end
private_class_method :new, :get_os_type
end
-end
\ No newline at end of file
+end