emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Matt Lundin <mdl@imapmail.org>
To: Org Mode <emacs-orgmode@gnu.org>
Subject: [PATCH 1/2] Ignore TODO keyword when taking title from headline
Date: Fri, 29 Apr 2011 20:54:00 -0400	[thread overview]
Message-ID: <87oc3oilit.fsf@fastmail.fm> (raw)


* lisp/org-bibtex.el (org-bibtex-headline): When taking title from
  headline, grab only the headline text, not metadata.
---
When generating an autokey or exporting to bibtex, the metadata (e.g.,
the TODO keyword) was being included in the title. This patch ensures
that only the headline text is included.

 lisp/org-bibtex.el |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/lisp/org-bibtex.el b/lisp/org-bibtex.el
index f4614fb..fcb25ca 100644
--- a/lisp/org-bibtex.el
+++ b/lisp/org-bibtex.el
@@ -289,7 +289,7 @@ IDs must be unique."
 			    (lambda (field)
 			      (let ((value (or (org-bibtex-get (from field))
 					       (and (equal :title field)
-						    (org-get-heading)))))
+						    (nth 4 (org-heading-components))))))
 				(when value (cons (from field) value))))
 			    (flatten
 			     (val :required (val (to type) org-bibtex-types))
-- 
1.7.5

                 reply	other threads:[~2011-04-30  1:19 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87oc3oilit.fsf@fastmail.fm \
    --to=mdl@imapmail.org \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).