emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <n.goaziou@gmail.com>
To: Daniel Clemente <n142857@gmail.com>
Cc: org-mode Mailinglist <emacs-orgmode@gnu.org>
Subject: Re: [patch] bug in export due to org-list-automatic-rules
Date: Wed, 08 Sep 2010 16:36:48 +0200	[thread overview]
Message-ID: <87vd6gjo8v.wl%n.goaziou@gmail.com> (raw)
In-Reply-To: <87vd6htl8c.wl%n142857@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1073 bytes --]

Hello,
>>>>> Daniel Clemente writes:

> Hi. This change in org.el (commit
> fd16515b4a88d48362223b19c511c4973cdbc84c, 2010-08-07 18:31:54):

>      '("^[ \t]*\\([-+*]\\|[0-9]+[.)][ \t]+\\(?:\\[@start:[0-9]+\\][
> \t]*\\)?\\)\\(\\[[- X]\\]\\)" 2 'org-checkbox prepend) - (if
> org-provide-checkbox-statistics + (if (cdr (assq 'checkbox
> org-list-automatic-rules))
> '("\\[\\([0-9]*%\\)\\]\\|\\[\\([0-9]*\\)/\\([0-9]*\\)\\]" (0
> (org-get-checkbox-statistics-face) t)))


>   made this command stop working:

> $ emacs --batch --load=/w/org-mode/lisp/org.el --visit
> ~/org-httptest/io.org --funcall org-export-as-html-batch File mode
> specification error: (void-variable org-list-automatic-rules)
> Loading vc-git... Exporting... Symbol's value as variable is void:
> org-list-automatic-rules

I'm not sure about this one. It's more a problem of require,
defcustom, and that kind of things than truly a list problem.

Just in case, I'm submitting this patch, but I'm pretty sure there's
something cleaner to do about it... but that still eludes me.

Regards,

-- Nicolas


[-- Attachment #2: 0002-Fix-void-variable-org-list-automatic-rules-error.patch --]
[-- Type: text/plain, Size: 1149 bytes --]

From a4f9d65882259348471a8b68890e7faea23d4a1d Mon Sep 17 00:00:00 2001
From: Nicolas Goaziou <n.goaziou@gmail.com>
Date: Wed, 8 Sep 2010 16:25:47 +0200
Subject: [PATCH 2/2] Fix void-variable org-list-automatic-rules error

* org.el (org-set-font-lock-defaults): as `org-list-automatic-rules'
  may be undefined under certain circumstances, first test if it
  exists before checking rules.
---
 lisp/org.el |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/lisp/org.el b/lisp/org.el
index 10b4d3f..fb2075e 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -5471,7 +5471,8 @@ needs to be inserted at a specific position in the font-lock sequence.")
 	   ;; Checkboxes
 	   '("^[ \t]*\\(?:[-+*]\\|[0-9]+[.)]\\)[ \t]+\\(?:\\[@\\(?:start:\\)?[0-9]+\\][ \t]*\\)?\\(\\[[- X]\\]\\)"
 	     1 'org-checkbox prepend)
-	   (if (cdr (assq 'checkbox org-list-automatic-rules))
+	   (if (and (fboundp 'org-list-automatic-rules)
+		    (cdr (assq 'checkbox org-list-automatic-rules)))
 	       '("\\[\\([0-9]*%\\)\\]\\|\\[\\([0-9]*\\)/\\([0-9]*\\)\\]"
 		 (0 (org-get-checkbox-statistics-face) t)))
 	   ;; Description list items
-- 
1.7.2.3


[-- Attachment #3: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

      parent reply	other threads:[~2010-09-08 14:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-07 19:19 bug in export due to org-list-automatic-rules Daniel Clemente
2010-09-07 22:09 ` Noorul Islam
2010-09-13  9:47   ` Daniel Clemente
2010-09-08 14:36 ` Nicolas Goaziou [this message]

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=87vd6gjo8v.wl%n.goaziou@gmail.com \
    --to=n.goaziou@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=n142857@gmail.com \
    /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).