diff options
author | Arnaud Fontaine <arnau@debian.org> | 2011-04-19 06:14:10 +0200 |
---|---|---|
committer | Lucas Bonnet <lucas@rincevent.net> | 2011-04-19 08:43:19 +0200 |
commit | 716975560a3385c4955ef1481f4994567dc66830 (patch) | |
tree | c39e3eb648839e8c0d20f67bb502145ea0cffee3 /lisp | |
parent | e87bcd69dfcdc63888933cc04bab2081e10494b7 (diff) |
Create cache directory if it does not already exist.
Following the quickstart guide, then adding a directory tree after
creating a playlist, an error message is displayed upon leaving Emacs
as the cache directory does not exist.
Signed-off-by: Lucas Bonnet <lucas@rincevent.net>
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/emms-cache.el | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lisp/emms-cache.el b/lisp/emms-cache.el index 4741cbf..4f96898 100644 --- a/lisp/emms-cache.el +++ b/lisp/emms-cache.el @@ -140,6 +140,8 @@ This is used to cache over emacs sessions.") emms-cache-db) (when (fboundp 'set-buffer-file-coding-system) (set-buffer-file-coding-system emms-cache-file-coding-system)) + (unless (file-directory-p (file-name-directory emms-cache-file)) + (make-directory (file-name-directory emms-cache-file))) (write-region (point-min) (point-max) emms-cache-file) (kill-buffer (current-buffer)) (message "Saving emms track cache...done") |