瀏覽代碼

Fix bug with recursive publishing and the publishing directory.

This one has haunted us for a long time......
Carsten Dominik 16 年之前
父節點
當前提交
d2697cf11e
共有 4 個文件被更改,包括 10 次插入3 次删除
  1. 1 1
      ORGWEBPAGE/Changes.org
  2. 3 0
      ORGWEBPAGE/index.org
  3. 3 0
      lisp/ChangeLog
  4. 3 2
      lisp/org-publish.el

+ 1 - 1
ORGWEBPAGE/Changes.org

@@ -161,7 +161,7 @@
     (the directory structure of the source files is reflected in
     the index).  The default is `tree'.
 
-    Thanks to Sebastian Rose for the patch.
+    Thanks to Manuel Hermenegildo for the patch.
 
 * Version 6.05
 

+ 3 - 0
ORGWEBPAGE/index.org

@@ -72,6 +72,9 @@ the command line....):
 
 : git clone git://repo.or.cz/org-mode.git
 
+Some more information about this can be found in the FAQ, under
+/How can I keep track of changes in my Org files?/.
+
 ** Alternative distributions
 
    There are several alternative distrbutions of Org:

+ 3 - 0
lisp/ChangeLog

@@ -1,5 +1,8 @@
 2008-07-25  Carsten Dominik  <dominik@science.uva.nl>
 
+	* org-publish.el (org-publish-file): Make sure the directory match
+	for the publishing directory works correctly.
+
 	* org-agenda.el (org-agenda-execute-calendar-command)
 	(org-agenda-diary-entry): Additional optional argument.
 

+ 3 - 2
lisp/org-publish.el

@@ -554,6 +554,7 @@ See `org-publish-org-to' to the list of arguments."
 					  (abbreviate-file-name filename))))
 		      (error "Can't publish file outside of a project")))))
 	   (project-plist (cdr project))
+	   (ftname (file-truename file-name))
 	   (publishing-function
 	    (or (plist-get project-plist :publishing-function)
 		'org-publish-org-to-html))
@@ -565,8 +566,8 @@ See `org-publish-org-to' to the list of arguments."
       (setq tmp-pub-dir
 	    (file-name-directory
 	     (concat pub-dir
-		     (and (string-match (regexp-quote base-dir) filename)
-			  (substring filename (match-end 0))))))
+		     (and (string-match (regexp-quote base-dir) ftname)
+			  (substring ftname (match-end 0))))))
       (if (listp publishing-function)
 	  ;; allow chain of publishing functions
 	  (mapc (lambda (f)