emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] :EXPORT_FILE_NAME: in new exporter possible?


From: Bastien
Subject: Re: [O] :EXPORT_FILE_NAME: in new exporter possible?
Date: Mon, 25 Mar 2013 19:52:24 +0100
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.3.50 (gnu/linux)

Achim Gratz <address@hidden> writes:

> talking different implementations of the second point above.  But given
> that Gnus expects to use a major mode with no setup, why not give them
> this:
>
> (define-derived-mode org-safe-mode org-mode "Org-Safe"
> ;; docstring etc.
> )

My feeling is that having a new mode just for preventing users to read
setup files is too much.  Do you have an idea on how to make org-safe-mode
not too heavy?

> and then conditionalize on the value of mode-name instead of an extra
> variable that they should bind?  

The extra defcustom is useful IMHO: the problem we have in Gnus, users
will have it anytime when opening a file that is not theirs and that
contains a #+SETUPFILE (e.g. files in Worg.)

Paranoids (or those who don't use #+SETUPFILE) will probably want to
be asked when Org tries to read an arbitrary file in their paths.
Others will just set this to (setq org-read-setup-file t).

So even if we have a org-safe-mode, I don't see how it will spare us
with the cost of a new option.

> This would also help to later add more
> "safe" functionality without changing things again and again in Org, Gnus
> or elsewhere.  For example, not running source blocks (we already have a
> way of doing that for export, so it shouldn't be hard to add this).

Yeah, I see where you go, but you know my dreadful tendency to favor
actual things against potential ones, and to go the ugly way rather
than going the clean one :)

Half-joking -- the thing is I really don't know what org-safe-mode
would look like, where else it would be useful, and how it spares us
the option for paranoid.  If you can help on each of these three
points, that'd great (no hurry, as I don't know if I'll have time to
follow this thread in the next few days.)

> I'm not arguing against your fix, I'd just prefer we'd start with something
> we just need to extend into a proper safe-mode instead of having to start
> again from scratch after hot-fixing this unfortunate interaction with Gnus
> (and I still don't know how Gnus gets there, anyway).

See my second patch, it gives directions on the Gnus side.

-- 
 Bastien



reply via email to

[Prev in Thread] Current Thread [Next in Thread]