Ver código fonte

Create publishing directory if it does not yet exist.

Patch from Sebastian Rose.
Carsten Dominik 17 anos atrás
pai
commit
155213dc11
2 arquivos alterados com 5 adições e 0 exclusões
  1. 3 0
      lisp/ChangeLog
  2. 2 0
      lisp/org-publish.el

+ 3 - 0
lisp/ChangeLog

@@ -1,5 +1,8 @@
 2008-05-16  Carsten Dominik  <dominik@science.uva.nl>
 
+	* org-publish.el (org-publish-attachment): Create publishing
+	directory if it does not yet exist.
+
 	* org-table.el (org-calc-default-modes): Change default number
 	format to (float 8).
 

+ 2 - 0
lisp/org-publish.el

@@ -512,6 +512,8 @@ See `org-publish-org-to' to the list of arguments."
     (require 'eshell)
     (require 'esh-maint)
     (require 'em-unix))
+  (unless (file-directory-p pub-dir)
+    (make-directory pub-dir t))
   (eshell/cp filename pub-dir))
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;