From 83e82f9ccd837e2e878e7bbeb68c54f19ca9d0e2 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Tue, 19 May 2009 17:46:09 +0200 Subject: [PATCH] Publishing: Fix `C-u C-c C-e X'. Publishing a project with prefix argument to force publishing was broken. Actually, the entire interactive side of this function was implemented badly. Fixed now. --- lisp/ChangeLog | 3 +++ lisp/org-publish.el | 18 +++++++++--------- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c22f4ee85..986c8d2d0 100755 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2009-05-19 Carsten Dominik + * org-publish.el (org-publish): Make this function behave + correctly in interactive use when called with a prefix argument. + * org.el (org-todo-statistics-hook): New hook. (org-update-parent-todo-statistics): Use new hook. (org-log-into-drawer): New function. diff --git a/lisp/org-publish.el b/lisp/org-publish.el index 13114cf07..a80f72ff0 100644 --- a/lisp/org-publish.el +++ b/lisp/org-publish.el @@ -600,18 +600,18 @@ Default for INDEX-FILENAME is 'sitemap.org'." ;;;###autoload (defun org-publish (project &optional force) "Publish PROJECT." - (interactive "P") + (interactive + (list + (assoc (org-ido-completing-read + "Publish project: " + org-publish-project-alist nil t) + org-publish-project-alist) + current-prefix-arg)) (setq org-publish-initial-buffer (current-buffer)) (save-window-excursion - (let* ((force current-prefix-arg) - (org-publish-use-timestamps-flag + (let* ((org-publish-use-timestamps-flag (if force nil org-publish-use-timestamps-flag))) - (org-publish-projects - (list (or project - (assoc (org-ido-completing-read - "Publish project: " - org-publish-project-alist nil t) - org-publish-project-alist))))))) + (org-publish-projects (list project))))) ;;;###autoload (defun org-publish-all (&optional force)