Carsten Dominik 17 år sedan
förälder
incheckning
05d3162553
4 ändrade filer med 22 tillägg och 14 borttagningar
  1. 3 0
      ChangeLog
  2. 4 1
      Makefile
  3. 4 2
      lisp/org-archive.el
  4. 11 11
      lisp/org-clock.el

+ 3 - 0
ChangeLog

@@ -1,5 +1,8 @@
 2008-04-25  Carsten Dominik  <dominik@science.uva.nl>
 
+	* lisp/org-archive.el (org-extract-archive-file): Handle the
+	special case where the file name is the empty string.
+
 	* Makefile (BATCH): Fix the path to the local lisp files.
 
 	* lisp/org.el (org-emphasis-alist): Use a different face for

+ 4 - 1
Makefile

@@ -31,7 +31,7 @@ infodir = $(prefix)/info
 # BATCH=$(EMACS) -batch -q -eval "(add-to-list (quote load-path) \".\")"
 
 BATCH=$(EMACS) -batch -q -eval                             \
- "(progn (add-to-list (quote load-path) \"./lisp\")             \
+ "(progn (add-to-list (quote load-path) (expand-file-name \"./lisp/\")) \
         (add-to-list (quote load-path) \"$(lispdir)\"))"
 
 # Specify the byte-compiler for compiling org-mode files
@@ -240,6 +240,9 @@ relup:
 	make upload_release
 	make upload_manual
 
+db:
+	grep -e '(debug)' lisp/*el
+
 cleanelc:
 	rm -f $(ELCFILES)
 cleandoc:

+ 4 - 2
lisp/org-archive.el

@@ -139,8 +139,10 @@ archive file is."
 (defun org-extract-archive-file (&optional location)
   (setq location (or location org-archive-location))
   (if (string-match "\\(.*\\)::\\(.*\\)" location)
-      (expand-file-name
-       (format (match-string 1 location) buffer-file-name))))
+      (if (= (match-beginning 1) (match-end 1))
+	  (buffer-file-name)
+	(expand-file-name
+	 (format (match-string 1 location) buffer-file-name)))))
 
 (defun org-extract-archive-heading (&optional location)
   (setq location (or location org-archive-location))

+ 11 - 11
lisp/org-clock.el

@@ -101,6 +101,16 @@ When clocking into a task and the clock is currently running, this marker
 is moved to the position of the currently running task and continues
 to point there even after the task is clocked out.")
 
+(defvar org-clock-default-task (make-marker)
+  "Marker pointing to the default task that should clock time.
+The clock can be made to switch to this task after clocking out
+of a different task.")
+
+(defvar org-clock-interrupted-task (make-marker)
+  "Marker pointing to the default task that should clock time.
+The clock can be made to switch to this task after clocking out
+of a different task.")
+
 (defun org-clock-history-push (&optional pos buffer)
   (let ((m (org-last org-clock-history)))
     (move-marker m (or pos (point)) buffer)
@@ -113,7 +123,7 @@ to point there even after the task is clocked out.")
 (defun org-clock-select-task (&optional prompt)
   "Select a task that recently was associated with clocking."
   (interactive)
-  (let (sel-list rpl file task (i 0))
+  (let (sel-list rpl file task (i 0) s)
     (save-window-excursion
       (org-switch-to-buffer-other-window
        (get-buffer-create "*Clock Task Select*"))
@@ -159,16 +169,6 @@ to point there even after the task is clocked out.")
 	(insert (format "[%c] %-15s %s\n" i cat task))
 	(cons i marker)))))
   
-(defvar org-clock-default-task (make-marker)
-  "Marker pointing to the default task that should clock time.
-The clock can be made to switch to this task after clocking out
-of a different task.")
-
-(defvar org-clock-interrupted-task (make-marker)
-  "Marker pointing to the default task that should clock time.
-The clock can be made to switch to this task after clocking out
-of a different task.")
-
 (defun org-update-mode-line ()
   (let* ((delta (- (time-to-seconds (current-time))
                    (time-to-seconds org-clock-start-time)))