From mboxrd@z Thu Jan 1 00:00:00 1970 From: Noorul Islam K M Subject: Re: org-default-notes-file Date: Mon, 18 Oct 2010 15:33:22 +0530 Message-ID: <87lj5vom1h.fsf@noorul.maa.corp.collab.net> References: <4CBBEC97.5000402@dayspringpublisher.com> <878w1wotrh.fsf@noorul.maa.corp.collab.net> <4CBC0BC1.40304@dayspringpublisher.com> <87tykjooja.fsf@noorul.maa.corp.collab.net> <4CBC101F.3020103@dayspringpublisher.com> <87pqv7oo04.fsf@noorul.maa.corp.collab.net> <4CBC192C.1010700@dayspringpublisher.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from [140.186.70.92] (port=34081 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P7man-0006dq-CU for emacs-orgmode@gnu.org; Mon, 18 Oct 2010 06:05:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P7mak-0003y0-Df for emacs-orgmode@gnu.org; Mon, 18 Oct 2010 06:05:21 -0400 Received: from mail-gx0-f169.google.com ([209.85.161.169]:35177) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P7mak-0003xv-73 for emacs-orgmode@gnu.org; Mon, 18 Oct 2010 06:05:18 -0400 Received: by gxk27 with SMTP id 27so395227gxk.0 for ; Mon, 18 Oct 2010 03:05:17 -0700 (PDT) In-Reply-To: <4CBC192C.1010700@dayspringpublisher.com> (Louis Turk's message of "Mon, 18 Oct 2010 17:53:48 +0800") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Louis Turk Cc: emacs-orgmode@gnu.org Louis Turk writes: > On 10/18/2010 05:20 PM, Noorul Islam K M wrote: >> Louis Turk writes: >> >>> On 10/18/2010 05:09 PM, Noorul Islam K M wrote: >>> >>>> Louis Turk writes: >>>> >>>>> On 10/18/2010 03:16 PM, Noorul Islam K M wrote: >>>>> >>>>>> Louis Turk writes: >>>>>> >>>>>>> Hi everyone, >>>>>>> >>>>>>> I trying to set up capture to use refile.org as the default notes file. >>>>>>> >>>>>>> lat-a-ws% locate refile.org >>>>>>> /home/lat/org/refile.org >>>>>>> lat-a-ws% >>>>>>> >>>>>>> (setq org-default-notes-file "~/org/refile.org") >>>>>>> >>>>>>> But I get: >>>>>>> >>>>>>> Debugger entered--Lisp error: (void-function org-string-nw-p) >>>>>>> (org-string-nw-p file) >>>>>>> (or (org-string-nw-p file) org-default-notes-file (error "No notes >>>>>>> file specified, and no default available")) >>>>>>> (setq file (or (org-string-nw-p file) org-default-notes-file (error >>>>>>> "No notes file specified, and no default available"))) >>>>>>> org-capture-target-buffer("~/org/refile.org") >>>>>>> (set-buffer (org-capture-target-buffer (nth 1 target))) >>>>>>> >>>>>>> How do I fix this? >>>>>>> >>>>>> This function is defined in org-macs.el. I think you should have in your >>>>>> .emacs. >>>>>> >>>>>> (require 'org-macs) >>>>>> >>>>>> Thanks and Regards >>>>>> Noorul >>>>> Thanks for responding, but that doesn't seem to cure the problem. I >>>>> still get the same error message. >>>>> >>>> Which version of emacs and org-mode are you using? >>>> >>>> M-x emacs-version >>>> M-x org-version >>>> >>>> Thanks and Regards >>>> Noorul >>> GNU Emacs 23.2.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.20.0) of >>> 2010-05-08 on pidsley.hoetzel.info >>> >>> Org-mode version 6.33x (release_7.01h.718.g0cb3c5.dirty) >>> >>> also, I'm using archlinux >>> >> I think you should use "Reply-To All" so that everyone in the list can >> see your message and help out. > Thanks. I didn't realize I wasn't replying to the list. >> It looks like there is a collision of org-mode versions? Do you have >> multiple org-mode installations? > Not on purpose, but probably. I think I used git to get the latest > org-mode. >> I think 6.33x is the one that comes with emacs and release 7.01h is the >> latest. Ensure that you have the latest version ahead in load path. >> >> Thanks and Regards >> Noorul > This is my .emacs, if that will help. Perhaps something in my .emacs > is conflicting. It probably needs a lot of cleaning up. > > (custom-set-variables > ;; custom-set-variables was added by Custom. > ;; If you edit it by hand, you could mess it up, so be careful. > ;; Your init file should contain only one such instance. > ;; If there is more than one, they won't work right. > '(canlock-password "129de665b1f8f1c95eaaa9daca897b054d323b2b") > '(column-number-mode t) > '(current-language-environment "UTF-8") > '(debug-on-error t) > '(muse-project-alist (quote (("WikiPlanner" ("~/plans" :default > "index" :major-mode planner-mode :visit-link planner-visit-link))))) > '(org-agenda-files (quote ("~/org/anniversaries.org" > "~/org/schedule.org" "~/org/projects.org"))) > '(safe-local-variable-values (quote ((Package . CL-PPCRE) (Syntax > . COMMON-LISP) (Package . CL-USER) (Base . 10)))) > '(save-place t nil (saveplace)) > '(scroll-bar-mode (quote right)) > '(show-paren-mode t) > '(size-indication-mode t) > '(uniquify-buffer-name-style (quote forward) nil (uniquify)) > '(vc-handled-backends (quote (Git SVN CVS RCS SCCS Arch)))) > (custom-set-faces > ;; custom-set-faces was added by Custom. > ;; If you edit it by hand, you could mess it up, so be careful. > ;; Your init file should contain only one such instance. > ;; If there is more than one, they won't work right. > '(default ((t (:inherit nil :stipple nil :background "honeydew" > :foreground "black" :inverse-video nil :box nil :strike-through nil > :overline nil :underline nil :slant normal :weight normal :height 136 > :width normal :foundry "unknown" :family "Gentium"))))) > (global-set-key "\C-x\C-m" 'execute-extended-command) > (global-set-key "\C-c\C-m" 'execute-extended-command) > ;(setq custom-file "~/.emacs-custom.elc") > ;(load custom-file) > (setq inhibit-splash-screen '(t)) > > (put 'downcase-region 'disabled nil) > (put 'upcase-region 'disabled nil) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Maltron keyboard navagation > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > ;; Moving down ---------------- > (global-set-key (kbd "s-k") 'next-line) > (global-set-key (kbd "s-o") 'forward-char) > (global-set-key (kbd "s-r") 'forward-word) > (global-set-key (kbd "s-'") 'forward-sentence) > (global-set-key (kbd "s-l") 'forward-paragraph) > (global-set-key (kbd "s-z") 'forward-page) > (global-set-key (kbd "s-x") 'end-of-buffer) > > ;; Moving up --------------------- > (global-set-key (kbd "s-u") 'previous-line) > (global-set-key (kbd "s-t") 'backward-char) > (global-set-key (kbd "s-d") 'backward-word) > (global-set-key (kbd "s-m") 'backward-sentence) > (global-set-key (kbd "s-v") 'backward-paragraph) > (global-set-key (kbd "s-w") 'backward-page) > (global-set-key (kbd "s-;") 'beginning-of-buffer) > > ;; Move to middle ---------------- > (defun goto-middle-of-line () > (interactive) > (let ((begin (progn (beginning-of-line) (point))) > (end (progn (end-of-line) (point)))) > (goto-char (/ (+ begin end) 2)))) > (global-set-key (kbd "s-h") 'goto-middle-of-line) > > ;; Search forward > (global-set-key (kbd "C-s-=") 'isearch-backward) > (global-set-key (kbd "s-=") 'isearch-forward) > > ;; Move the contents of the buffer up or down without changing the > cursor position ====== > (global-set-key (kbd "M-") (lambda () (interactive) (scroll-up 1))) > (global-set-key (kbd "M-") (lambda () (interactive) (scroll-down 1))) > > ;; ===================================================== > (setq x-select-enable-clipboard t) > > (setq imap-log t) > > ;; I hate tabs! > (setq-default indent-tabs-mode nil) > > ;; Remove tabs while saving. > (defun java-mode-untabify () > (save-excursion > (goto-char (point-min)) > (while (re-search-forward "[ \t]+$" nil t) > (delete-region (match-beginning 0) (match-end 0))) > (goto-char (point-min)) > (if (search-forward "\t" nil t) > (untabify (1- (point)) (point-max)))) > nil) > > (add-hook 'java-mode-hook > '(lambda () > (make-local-variable 'write-contents-hooks) > (add-hook 'write-contents-hooks 'java-mode-untabify))) > > > (set-background-color "honeydew") > > ;(set-face-font 'default "-bitstream-bitstream vera sans > mono-medium-r-normal-*-*-120-100-100-m-0-iso8859-16") > ;(set-face-font 'default "-jmk-neep > alt-medium-r-*-*-20-*-*-*-c-*-iso8859-1") > ;(set-face-font 'default "*courier-bold-r*140-100-100*") > > (setq-default truncate-lines t) > > (setq imap-log t) > > (setq load-path (cons "/usr/bin" load-path)) > ;(load "rebview") > ;(require 'rebol) > ;(add-hook 'rebol-mode-hook (lambda () (font-lock-mode 1))) > ;(setq auto-mode-alist > ; (cons (cons "\\.r$" 'rebol-mode) auto-mode-alist)) > > ;(load-file "/home/lat/emacros/emacros.elc") > > ;(global-set-key "\C-cA" 'emacros-name-last-kbd-macro-add) > ;(global-set-key "\C-ce" 'emacros-execute-named-macro) > ;(global-set-key "\C-cc" 'emacros-auto-execute-named-macro) > > ;; Display full path name if appropriate on mode line. > (add-hook 'find-file-hooks > '(lambda () > (setq mode-line-buffer-identification 'buffer-file-truename))) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; TRAMP settings > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (setq tramp-default-method "psftp") > (setq tramp-default-user "daysprin") > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; GIT settings > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (load "/usr/share/doc/git-core/contrib/emacs/git.el" t) > (load "/usr/share/doc/git-core/contrib/emacs/git-blame.el" t) > (load "/usr/share/doc/git-core/contrib/emacs/vc-git.el" t) > (add-to-list 'vc-handled-backends 'GIT) > > > (defmacro elscreen-create-automatically (ad-do-it) > (` (if (not (elscreen-one-screen-p)) > (, ad-do-it) > (elscreen-create) > (elscreen-notify-screen-modification 'force-immediately) > (elscreen-message "New screen is automatically created")))) > > (defadvice elscreen-next (around elscreen-create-automatically activate) > (elscreen-create-automatically ad-do-it)) > > (defadvice elscreen-previous (around elscreen-create-automatically > activate) > (elscreen-create-automatically ad-do-it)) > > (defadvice elscreen-toggle (around elscreen-create-automatically activate) > (elscreen-create-automatically ad-do-it)) > > (defun elscreen-frame-title-update () > (when (elscreen-screen-modified-p 'elscreen-frame-title-update) > (let* ((screen-list (sort (elscreen-get-screen-list) '<)) > (screen-to-name-alist (elscreen-get-screen-to-name-alist)) > (title (mapconcat > (lambda (screen) > (format "%d%s %s" > screen (elscreen-status-label screen) > (get-alist screen screen-to-name-alist))) > screen-list " "))) > (if (fboundp 'set-frame-name) > (set-frame-name title) > (setq frame-title-format title))))) > > (eval-after-load "elscreen" > '(add-hook 'elscreen-screen-update-hook 'elscreen-frame-title-update)) > > > > (require 'executable) > > ;(let ((w3mmee (executable-find "w3mmee")) > ; (mbconv (executable-find "mbconv"))) > ; (when (and w3mmee mbconv) > ; (setq w3m-command w3mmee))) > > ;(require 'w3m) > > > ;;---------------- Planner --------------------------- > > (add-to-list 'load-path "~/elisp/muse/lisp") > (add-to-list 'load-path "~/elisp/planner") > (add-to-list 'load-path "~/elisp/remember") > > (setq planner-project "WikiPlanner") > (setq muse-project-alist > '(("WikiPlanner" > ("~/plans" ;; Or wherever you want your planner files to be > :default "index" > :major-mode planner-mode > :visit-link planner-visit-link)))) > (require 'planner) > > ;;------------ > > (setq common-lisp-hyperspec-root "/home/lat/l/Lisp HyperSpec/") > > ;;-------------- "open file in the same window when clicking on it in > dired" by mnemonikk > > ;(defadvice dired-mouse-find-file-other-window (around > dired-mouse-find-file-advice activate) > ; (flet ((find-file-other-window (filename) (find-file filename))) > ; ad-do-it)) > > (defadvice dired-mouse-find-file-other-window (around > dired-mouse-find-file-advice activate) > (flet ((find-file-other-window (filename) (find-file filename)) > (dired-other-window (filename) (dired filename))) > ad-do-it)) > > (global-visual-line-mode 1) ; 1 for on, 0 for off. > (global-linum-mode 1) ; always show line numbers > > > ;;------------------- > ;; highlight the current line; set a custom face, so we can > ;; recognize from the normal marking (selection) > ;(defface hl-line '((t (:background "Yellow"))) > ; "Face to use for `hl-line-face'." :group 'hl-line) > ;(setq hl-line-face 'hl-line) > ;(global-hl-line-mode t) ; turn it on for all modes by default > ;;------------------- > > ;; Support functions for `stesla-rotate-buffers'. From the EmacsWiki. > > (defvar stesla-hated-buffers '("KILL" "*Apropos*" "*Completions*" "*grep*" > ".newsrc-dribble" ".bbdb" "sent-mail" > "*vc*" > "*Compile-Log*" "*Help*" "*Messages*")) > > (defvar stesla-hated-buffer-regexps '("^ " "*Buffer" "^\\*trace" > "^\\*tramp")) > > (setq iswitchb-buffer-ignore (append stesla-hated-buffer-regexps > stesla-hated-buffers)) > > (defmacro stesla-buffer-regexp-mapcar (regexp buffers) > "Find BUFFERS whose name matches REGEXP" > `(mapcar (lambda (this-buffer) > (if (string-match ,regexp (buffer-name this-buffer)) > this-buffer)) > ,(if (symbolp buffers) (symbol-value buffers) buffers))) > > (defmacro stesla-hated-buffer-from-regexps (regexps) > "Generate a one-dimensional list of buffers that match REGEXPS" > (append > '(append) > (mapcar (lambda (regexp) > `(delete nil (stesla-buffer-regexp-mapcar ,regexp > (buffer-list)))) > (if (symbolp regexps) (symbol-value regexps) regexps)))) > > (defun stesla-delete-from-list (delete-these from-list) > "Delete DELETE-THESE from FROM-LIST." > (cond > ((car delete-these) > (if (member (car delete-these) from-list) > (stesla-delete-from-list (cdr delete-these) > (delete (car delete-these) from-list)) > (stesla-delete-from-list (cdr delete-these) from-list))) > (t from-list))) > > (defun stesla-hated-buffers () > "List of buffers I never want to see." > (delete nil > (append > (mapcar 'get-buffer stesla-hated-buffers) > (stesla-hated-buffer-from-regexps > stesla-hated-buffer-regexps)))) > > ;; `stesla-rotate-buffers': Like `bury-buffer' but with the capability to > ;; exclude certain specified buffers. > > (defun stesla-rotate-buffers (&optional n) > "Switch to the Nth next buffer. Negative arguments move backwards." > (interactive) > (unless n > (setq n 1)) > (let ((my-buffer-list > (stesla-delete-from-list (stesla-hated-buffers) > (buffer-list (selected-frame))))) > (switch-to-buffer > (if (< n 0) > (nth (+ (length my-buffer-list) n) > my-buffer-list) > (bury-buffer) > (nth n my-buffer-list))))) > > ;; Windows-style C-TAB and C-M-TAB to switch buffers. > > (global-set-key (kbd "C-") 'stesla-rotate-buffers) > (global-set-key (kbd "C-M-") (lambda () > (interactive) > (stesla-rotate-buffers -1))) > > ;; This is C-TAB and C-M-TAB for the Linux console. This requires special > ;; setup; namely, you need to load a keymap file with /usr/bin/loadkeys > ;; containing the following lines: > ;; > ;; control keycode 15 = Macro > ;; control alt keycode 15 = Pause > ;; > ;; If you actually -have- a key that generates the Macro or Pause > keysyms, you > ;; have a better keyboard than I. For me, this makes Emacs DWIW. > Credit for > ;; this hack goes to Alex Schroeder. > > (global-set-key (kbd "ESC [ M") 'stesla-rotate-buffers) > (global-set-key (kbd "ESC [ P") (lambda () > (interactive) > (stesla-rotate-buffers -1))) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; SLIME setup > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > ;(setq slime-lisp-implementations > ; '((sbcl ("sbcl" "--core" "/usr/bin/sbcl")))) > > ;; possibly controversial as a global default, but shipping a lisp > ;; that dies trying to talk to slime is stupid, so: > (set-language-environment "UTF-8") > (setq slime-net-coding-system 'utf-8-unix) > > ;; load slime: > (setq load-path (cons "/home/lat/clbuild/source/slime" load-path)) > (setq load-path (cons "/home/lat/clbuild/source/slime/contrib" load-path)) > (setq slime-backend "/home/lat/clbuild/.swank-loader.lisp") > (setq inhibit-splash-screen t) > (load "/home/lat/clbuild/source/slime/slime") > (setq inferior-lisp-program "/usr/local/bin/sbcl") > (setq slime-use-autodoc-mode nil) > (slime-setup '(slime-fancy slime-tramp slime-asdf)) > (slime-require :swank-listener-hooks) > (define-key slime-mode-map (kbd "C-M-x") 'slime-eval-defun) > > (setq slime-backend "/home/lat/clbuild/.swank-loader.lisp") > (setq inhibit-splash-screen t) > (load "/home/lat/clbuild/source/slime/slime") > (setq inferior-lisp-program "/usr/bin/sbcl") > (setq slime-use-autodoc-mode nil) > (slime-setup '(slime-fancy slime-tramp slime-asdf)) > (slime-require :swank-listener-hooks) > (define-key slime-mode-map (kbd "C-M-x") 'slime-eval-defun) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; AUCTEX settings > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (load "auctex.el" nil t t) > (load "preview-latex.el" nil t t) > > (setq TeX-PDF-mode t) > (defun pdfevince () > (add-to-list 'TeX-output-view-style > (quote ("^pdf$" "." "evince %o %(outpage)"))) > ) > > (add-hook 'LaTeX-mode-hook 'pdfevince t) ; AUCTeX LaTeX mode > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; erc --- irc client > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (add-to-list 'load-path "~/elisp/erc") > (require 'erc) > (setq erc-echo-notices-in-minibuffer-flag t) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Wanderlust > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > ;; autoload configuration > ;; (Not required if you have installed Wanderlust as XEmacs package) > (autoload 'wl "wl" "Wanderlust" t) > (autoload 'wl-other-frame "wl" "Wanderlust on new frame." t) > (autoload 'wl-draft "wl-draft" "Write draft with Wanderlust." t) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Misc. > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (global-auto-revert-mode t) > > (set-default-font "DejaVu Sans Mono-14") > (set-fontset-font (frame-parameter nil 'font) > 'han '("cwTeXHeiBold" . "unicode-bmp")) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; emacros > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (load-file "/home/lat/emacros/emacros.elc") > (global-set-key (kbd "") 'emacros-name-last-kbd-macro-add) > (global-set-key (kbd "C-M-x") 'slime-eval-defun) > (global-set-key "\C-cs" 'slime-selector) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Org-mode settings > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (add-to-list 'auto-mode-alist '("\\.org$" . org-mode)) > (global-set-key "\C-cl" 'org-store-link) > (global-set-key "\C-ca" 'org-agenda) > (global-font-lock-mode 1) > > (setq org-clock-persist t) > (setq org-clock-in-resume t) > (require 'org-clock) > (org-clock-persistence-insinuate) > > ;; (setq org-agenda-include-diary t) > > (setq org-agenda-skip-scheduled-if-done t) > (setq org-agenda-skip-deadline-if-done t) > (setq org-agenda-skip-timestamp-if-done t) > > (setq org-tag-alist '(("@malls-45" . ?m) ("@computers" . ?c) > ("@hardware" . ?h) ("@gov" . ?g) ("@books" . ?b))) > > ;(org-remember-insinuate) > ;(setq org-directory "~/org/") > ;(setq org-default-notes-file (concat org-directory "/notes.org")) > ;(define-key global-map "\C-cr" 'org-remember) > ;(setq org-remember-templates > ; '(("Journal" ?j "* %U %?\n\n %i\n %a" "~/org/journal.org" > ;"Journal"))) > > ;; popup alarm windows for org-mode ------------------- > http://article.gmane.org/gmane.emacs.orgmode/5271 > ;; Add appointments from the diary to the agenda at startup and make > org-agenda-redo rescan the appt list: > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Org-mode latex export book class > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (require 'org-latex) > > (add-to-list 'org-export-latex-classes > '("book" > "\\documentclass[11pt,letter]{book}" > ("\\part{%s}" . "\\part*{%s}") > ("\\chapter{%s}" . "\\chapter*{%s}") > ("\\section{%s}" . "\\section*{%s}") > ("\\subsection{%s}" . "\\subsection*{%s}") > ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))) > > (setq load-path (cons "/home/lat/org-mode/lisp/org-taskjuggler.el" > load-path)) > (add-to-list 'load-path "~/org-mode/lisp/") > (require 'org-taskjuggler) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Begin org-mode setting from norang > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (add-to-list 'load-path (expand-file-name "~/org-mode/lisp")) > (add-to-list 'auto-mode-alist '("\\.\\(org\\|org_archive\\|txt\\)$" > . org-mode)) > > (load-file "/home/lat/org-mode/lisp/org-capture.el") > > (require 'org-install) > ;; > ;; Standard key bindings > (global-set-key "\C-cl" 'org-store-link) > (global-set-key "\C-ca" 'org-agenda) > (global-set-key "\C-cb" 'org-iswitchb) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Org-mode for gnus > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (setq message-mode-hook > (quote (orgstruct++-mode > (lambda nil (setq fill-column 72) (flyspell-mode 1)) > turn-on-auto-fill > bbdb-define-all-aliases))) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Enable yasnippet > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (add-to-list 'load-path > "~/.emacs.d/plugins") > (require 'yasnippet-bundle) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Enable flyspell-mode > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > ;; Make TAB the yas trigger key in the org-mode-hook and enable > flyspell mode and autofill > (add-hook 'org-mode-hook > (lambda () > ;; yasnippet > (make-variable-buffer-local 'yas/trigger-key) > (org-set-local 'yas/trigger-key [tab]) > (define-key yas/keymap [tab] 'yas/next-field-group) > ;; flyspell mode for spell checking everywhere > (flyspell-mode 1) > ;; auto-fill mode on > (auto-fill-mode 1))) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; agenda setup > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (setq org-agenda-files (quote ("~/org/refile.org" > "~/org.org" > "~/org/schedule.org" > "~/org/npa.org" > "~/org/anniv.org"))) > > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Org-mode key bindings > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > ;; Custom Key Bindings > (global-set-key (kbd "") 'org-agenda) > (global-set-key (kbd "") 'bh/org-todo) > (global-set-key (kbd "") 'bh/widen) > (global-set-key (kbd "") 'set-truncate-lines) > (global-set-key (kbd "") 'org-cycle-agenda-files) > (global-set-key (kbd " b") 'bbdb) > (global-set-key (kbd " c") 'calendar) > (global-set-key (kbd " f") 'boxquote-insert-file) > (global-set-key (kbd " g") 'gnus) > (global-set-key (kbd " h") 'bh/hide-other) > > (defun bh/hide-other () > (interactive) > (save-excursion > (org-back-to-heading) > (org-shifttab) > (org-reveal) > (org-cycle))) > > (global-set-key (kbd " i") 'bh/org-info) > > (defun bh/org-info () > (interactive) > (info "~/org-mode/doc/org.info")) > > (global-set-key (kbd " I") 'bh/clock-in) > (global-set-key (kbd " O") 'bh/clock-out) > (global-set-key (kbd " r") 'boxquote-region) > (global-set-key (kbd " s") 'bh/go-to-scratch) > > (defun bh/go-to-scratch () > (interactive) > (switch-to-buffer "*scratch*") > (delete-other-windows)) > > (global-set-key (kbd " t") 'bh/insert-inactive-timestamp) > (global-set-key (kbd " u") 'bh/untabify) > > (defun bh/untabify () > (interactive) > (untabify (point-min) (point-max))) > > (global-set-key (kbd " v") 'visible-mode) > (global-set-key (kbd " SPC") 'bh/clock-in-last-task) > (global-set-key (kbd "C-") 'previous-buffer) > (global-set-key (kbd "C-x n r") 'narrow-to-region) > (global-set-key (kbd "C-") 'next-buffer) > (global-set-key (kbd "") 'org-clock-goto) > (global-set-key (kbd "C-") 'org-clock-in) > (global-set-key (kbd "C-s-") 'bh/save-then-publish) > (global-set-key (kbd "M-") 'org-resolve-clocks) > (global-set-key (kbd "C-M-r") 'org-capture) > (global-set-key (kbd "M-") (lambda () > (interactive) > (unless (buffer-modified-p) > (kill-buffer (current-buffer))) > (delete-frame))) > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; TODO keywords > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (setq org-todo-keywords '((sequence "TODO(t)" "|" "NEXT(n)" "|" > "DONE(d!)" "|" "CANC(n@)") > (sequence "lat(l)" "cgt(c)" "skt(s)" > "kiy(k)" "cet(e)" "lst(v)"))) > > (setq org-todo-keyword-faces > (quote (("TODO" :foreground "red" :weight bold) > ("NEXT" :foreground "blue" :weight bold) > ("DONE" :foreground "forest green" :weight bold) > ("CANC" :foreground "forest green" :weight bold) > ("WAITING" :foreground "yellow" :weight bold) > ("SOMEDAY" :foreground "goldenrod" :weight bold)))) > > > (setq org-use-fast-todo-selection t) > (setq org-treat-S-cursor-todo-selection-as-state-change nil) > > > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > ;;; Org Capture > ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; > > (require 'org-macs) > > ;(setq org-default-notes-file (concat org-directory "~/org/notes.org")) > ;(define-key global-map "\C-cc" 'org-capture) > > (setq org-default-notes-file "~/org/refile.org") > > ;; I use C-M-r to start capture mode > (global-set-key (kbd "C-M-r") 'org-capture) > > ;; 3 capture templates for TODO tasks, Notes, and org-protocol (untested) > (setq org-capture-templates (quote (("t" "todo" entry (file > "~/org/refile.org") "* TODO %? > %U > %a" :clock-in t :clock-resume t) > ("n" "note" entry (file > "~/org/refile.org") "* %? > :NOTE: > %U > %a > :CLOCK: > :END:" :clock-in t :clock-resume t) > ("w" "org-protocol" entry (file > "~/org/refile.org") "* TODO Review %c > %U" :immediate-finish t :clock-in t :clock-resume t)))) > > ;; Remove empty CLOCK drawers on clock out > (defun bh/remove-empty-drawer-on-clock-out () > (interactive) > (save-excursion > (beginning-of-line 0) > (org-remove-empty-drawer-at "CLOCK" (point)))) > > (add-hook 'org-clock-out-hook 'bh/remove-empty-drawer-on-clock-out 'append) > > ; Use IDO for target completion > (setq org-completion-use-ido t) > > ; Targets include this file and any file contributing to the agenda - > up to 5 levels deep > (setq org-refile-targets (quote ((org-agenda-files :maxlevel . 5) (nil > :maxlevel . 5)))) > > ; Targets start with the file name - allows creating level 1 tasks > (setq org-refile-use-outline-path (quote file)) > > ; Targets complete in steps so we start with filename, TAB shows the > next level of targets etc > (setq org-outline-path-complete-in-steps t) > > ; Allow refile to create parent tasks with confirmation > (setq org-refile-allow-creating-parent-nodes (quote confirm)) > > ; Use IDO only for buffers > ; set ido-mode to buffer and ido-everywhere to t via the customize interface > ; '(ido-mode (quote both) nil (ido)) > ; '(ido-everywhere t) > > Thanks again, > Lou Can you move following line to the beginning for org-mode settings? (add-to-list 'load-path "~/org-mode/lisp/") Thanks and Regards Noorul