[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [O] Alternate format for datetree
From: |
Nick Dokos |
Subject: |
Re: [O] Alternate format for datetree |
Date: |
Wed, 29 Aug 2012 10:17:20 -0400 |
Ian Barton <address@hidden> wrote:
> Thanks Nick. Hwever with the following minimal template, from the OP,
> I still get the error:
>
> ;; org-capture settings.
> (setq org-capture-templates
> `(("t" "test" entry
> (file+headline "~/file.org"
> ,(format "%s"
> (format-time-string "%m")))
> ,(format "** %s \n*** %s-%s \n**** [%s-%s-%s %s %s:%s] "
> (format-time-string "%d")
> (format-time-string "%Y")
> (format-time-string "%A")
> (format-time-string "%Y")
> (format-time-string "%m")
> (format-time-string "%d")
> (format-time-string "%a")
> (format-time-string "%H")
> (format-time-string "%M"))
> )))
>
I put this in a minimal .emacs and I *do not* get an error. Please try
the appended minimal .emacs (change the pathnames appropriately) with
emacs -q -l /path/to/minimal/.emacs
M-x org-capture RET t
M-x org-capture RET u
and post the backtrace if any. Both of them work fine for me. You are
sure you used a backquote?
Nick
--8<---------------cut here---------------start------------->8---
;;; -*- mode: emacs-lisp -*-
;;; constant part
(add-to-list 'load-path (expand-file-name "~/src/emacs/org/org-mode/lisp"))
(add-to-list 'load-path (expand-file-name
"~/src/emacs/org/org-mode/contrib/lisp"))
(add-to-list 'auto-mode-alist '("\\.\\(org\\|org_archive\\|txt\\)$" . org-mode))
(require 'org-install)
(setq debug-on-error t)
(setq debug-on-quit t)
(setq eval-expression-print-length nil)
(setq eval-expression-print-level nil)
(global-set-key "\C-cl" 'org-store-link)
(global-set-key "\C-ca" 'org-agenda)
;;; variable part
;; org-capture settings.
(setq org-capture-templates
`(("t" "test" entry
(file+headline "~/test.org"
,(format "%s"
(format-time-string "%m")))
,(format "** %s \n*** %s-%s \n**** [%s-%s-%s %s %s:%s] "
(format-time-string "%d")
(format-time-string "%Y")
(format-time-string "%A")
(format-time-string "%Y")
(format-time-string "%m")
(format-time-string "%d")
(format-time-string "%a")
(format-time-string "%H")
(format-time-string "%M"))
)
("u" "Test" entry
(file+headline "~/test.org"
,(format "%s %s"
(format-time-string "%B")
(format-time-string "%Y"))))))
--8<---------------cut here---------------end--------------->8---
- [O] Alternate format for datetree, c b, 2012/08/26
- Re: [O] Alternate format for datetree, John Hendy, 2012/08/26
- Re: [O] Alternate format for datetree, Nick Dokos, 2012/08/27
- Re: [O] Alternate format for datetree, John Hendy, 2012/08/27
- Re: [O] Alternate format for datetree, Ian Barton, 2012/08/28
- Re: [O] Alternate format for datetree, Nick Dokos, 2012/08/28
- Re: [O] Alternate format for datetree, Nick Dokos, 2012/08/28
- Re: [O] Alternate format for datetree, Ian Barton, 2012/08/29
- Re: [O] Alternate format for datetree,
Nick Dokos <=
- Re: [O] Alternate format for datetree, John Hendy, 2012/08/29
- Re: [O] Alternate format for datetree, Ian Barton, 2012/08/29