diff --git a/.gitignore b/.gitignore index 026cee63..38e5d00e 100644 --- a/.gitignore +++ b/.gitignore @@ -40,3 +40,5 @@ config/google-chrome /dotfiles/vim/bundle/* /dotfiles/wemo/cache gotools + +dotfiles/emacs.d/config.el \ No newline at end of file diff --git a/dotfiles/emacs.d/config.org b/dotfiles/emacs.d/config.org index 69c114eb..60bbd4a3 100644 --- a/dotfiles/emacs.d/config.org +++ b/dotfiles/emacs.d/config.org @@ -1,3 +1,4 @@ +#+BEGIN_SRC emacs-lisp ;; -*- lexical-binding: t; -*- ;; ============================================================================= ;; ___ _ __ ___ __ _ ___ ___ @@ -1119,7 +1120,7 @@ the same tree node, and the headline of the tree node in the Org-mode file." (setq org-show-notification-handler 'imalison:org-notify-notification-handler) (org-notify-add 'default '(:time "1h" :actions imalison:org-notify-notification-handler - :period "2m" :duration 60)) + :period "2m" :duration 60)) (org-notify-add 'default '(:time "100m" :actions imalison:org-notify-notification-handler :period "2m" :duration 60)) (org-notify-add 'urgent-second '(:time "3m" :actions (-notify/window -ding) @@ -1269,7 +1270,7 @@ the same tree node, and the headline of the tree node in the Org-mode file." ,(cons "A" (cons "High priority upcoming" this-week-high-priority)) ,(cons "d" (cons "Overdue tasks and due today" due-today)) ,(cons "r" (cons "Recently created" recently-created)) - ("h" "A, B priority:" tags-todo "+PRIORITY<\"C\"" + ("h" "A, B priority:" tags-todo "+PRIORITY<\"C\"" ((org-agenda-overriding-header "High Priority:"))) ("c" "At least priority C:" tags-todo "+PRIORITY<\"D\"" @@ -2572,3 +2573,4 @@ items follow a style that is consistent with other prog-modes." ;; Local Variables: ;; flycheck-disabled-checkers: (emacs-lisp-checkdoc) ;; End: +#+END_SRC diff --git a/dotfiles/emacs.d/init.el b/dotfiles/emacs.d/init.el new file mode 100644 index 00000000..71afcfba --- /dev/null +++ b/dotfiles/emacs.d/init.el @@ -0,0 +1,24 @@ +(require 'package) + +(add-to-list 'package-archives '("org" . "https://orgmode.org/elpa/") t) + +(defun ensure-packages-installed (packages) + (unless package-archive-contents + (package-refresh-contents)) + (mapcar + (lambda (package) + (if (package-installed-p package) + package + (progn (message (format "Installing package %s." package)) + (package-install package)))) + packages)) + +(package-initialize) +(ensure-packages-installed '(org-plus-contrib)) + +(org-babel-load-file + (concat (file-name-directory load-file-name) "config.org")) + +;; Local Variables: +;; flycheck-disabled-checkers: (emacs-lisp-checkdoc) +;; End: