summary refs log tree commit diff stats
path: root/emacs
diff options
context:
space:
mode:
authorAlan Pearce2013-05-03 09:04:33 +0100
committerAlan Pearce2013-05-03 09:04:33 +0100
commit72e2c1dfc5d880f65eb6935133880f122dbca9fd (patch)
treea7a30d21f8006aebfe5a57b84f7925c625cbcebf /emacs
parentd45621219fb0a77122e374af69855b0068f2c45d (diff)
downloaddotfiles-72e2c1dfc5d880f65eb6935133880f122dbca9fd.tar.lz
dotfiles-72e2c1dfc5d880f65eb6935133880f122dbca9fd.tar.zst
dotfiles-72e2c1dfc5d880f65eb6935133880f122dbca9fd.zip
Emacs: fix logic error in setting up load-path
Diffstat (limited to 'emacs')
-rw-r--r--emacs/init.el17
1 files changed, 13 insertions, 4 deletions
diff --git a/emacs/init.el b/emacs/init.el
index 7f6c873..f3277b1 100644
--- a/emacs/init.el
+++ b/emacs/init.el
@@ -26,11 +26,11 @@
               (if (and (not (string-prefix-p "." file))
                        (file-directory-p full-path))
                   (add-to-list 'load-path full-path))))
-          (directory-files *el-get-dir*))))
+          (directory-files path))))
 
 (if (file-exists-p (concat *el-get-dir* "el-get"))
-	(add-to-list 'load-path *el-get-dir*)
-    (add-subdirs-to-load-path *el-get-dir*)
+    (progn (add-subdirs-to-load-path *el-get-dir*)
+	   (add-to-list 'load-path *el-get-dir*))
   (unless (require 'el-get nil t)
     (with-current-buffer
       (url-retrieve-synchronously
@@ -578,7 +578,16 @@
 
                   org-blank-before-new-entry '((heading . t)
                                                (plain-list-item . auto))
-                  org-fontify-done-headline t))
+                  org-fontify-done-headline t)
+
+            (defadvice org-clock-in (after wicked activate)
+              "Mark STARTED when clocked in"
+              (save-excursion
+                (catch 'exit
+                  (org-back-to-heading t)
+                  (if (looking-at org-outline-regexp) (goto-char (1- (match-end 0))))
+                  (if (looking-at (concat " +" org-todo-regexp "\\( +\\|[ \t]*$\\)"))
+                      (org-todo "STARTED"))))))
   :init (setq org-replace-disputed-keys t
               org-todo-keywords '((sequence "TODO" "STARTED" "|" "DONE")
                                   (sequence "TOLEARN" "LEARNING" "LEARNED" "|" "MASTERED")