diff options
-rw-r--r-- | emms/jao-emms-lyrics.el | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/emms/jao-emms-lyrics.el b/emms/jao-emms-lyrics.el index 8a0b0ce..9bf00b2 100644 --- a/emms/jao-emms-lyrics.el +++ b/emms/jao-emms-lyrics.el @@ -1,6 +1,6 @@ ;; jao-emms-lyrics.el -- simple show lyrics in emms -;; Copyright (C) 2009, 2010, 2017 Jose Antonio Ortega Ruiz +;; Copyright (C) 2009, 2010, 2017, 2019 Jose Antonio Ortega Ruiz ;; Author: Jose Antonio Ortega Ruiz <jao@gnu.org> ;; Start date: Sat Jul 04, 2009 13:41 @@ -98,6 +98,8 @@ (defun jao-emms-lyrics--download (artist title) (message "Retrieving lyrics...") + (or (executable-find "glyrc") + (error "glyrc not installed")) (let ((fn (jao-emms-lyrics--filename artist title))) (shell-command-to-string (format "glyrc lyrics -n 1-8 -Y -a %s -t %s -w %s" (shell-quote-argument artist) @@ -113,7 +115,9 @@ (buffer (jao-emms-lyrics-buffer)) (cached (and (not force) (jao-emms-lyrics--get-cached artist title))) (cached (and (not (zerop (length cached))) cached)) - (lyrics (or cached (jao-emms-lyrics--download artist title))) + (lyrics (or cached + (jao-emms-lyrics--download artist title) + (jao-emms-lyrics--download "" title))) (inhibit-read-only t)) (with-current-buffer buffer (delete-region (point-min) (point-max)) |