From: Nicolas Goaziou <n.goaziou@gmail.com>
To: Rick Frankel <rick@rickster.com>
Cc: Achim Gratz <Stromeko@nexgo.de>, emacs-orgmode@gnu.org
Subject: Re: [RFC] Slight change to asynchronous export
Date: Wed, 30 Oct 2013 11:00:32 +0100 [thread overview]
Message-ID: <8738njaxj3.fsf@gmail.com> (raw)
In-Reply-To: <0dccb1354fae8c7a3ce2c505e436bb2e@mail.rickster.com> (Rick Frankel's message of "Tue, 29 Oct 2013 13:42:28 -0400")
[-- Attachment #1: Type: text/plain, Size: 1432 bytes --]
Helo,
Rick Frankel <rick@rickster.com> writes:
> On 2013-10-29 04:35, Nicolas Goaziou wrote:
>> Achim Gratz <Stromeko@nexgo.de> writes:
>>
>> Nicolas Goaziou writes:
>> At the moment, by default, external emacs process for asynchronous
>> export is called with:
>>
>> /path/to/emacs -Q --batch -l org-export-async-init-file ... export
>> stuff...
>>
>> where `org-export-async-init-file' defaults to `user-init-file'. It is,
>> by default, not the same as calling "emacs", because of the "-Q".
>>
>> That's a good thing, I'd say. There is a lot of stuff going on in init
>> files that you most likely don't want done when firing Emacs off in the
>> background. That is especially true of some site-init files that you
>> typically have no control over.
>>
>> As I said, it wouldn't be worse than the current situation.
>>
>> If you don't make this the default then no harm is done, I guess.
>>
>> The whole point of this change is to change the default value. If
>> there's no interest in it, I won't bother making it.
>
> I'm all for it. The current default is, IMHO, the worst of both worlds
> since, by loading my init but leaving out site-lisp i end up w/ the
> wrong org loaded (the one from the default distribution, not
> site-lisp) unless I make explicit reference to the development org in
> site-lisp.
For reference, here is the suggested patch.
Is there any strong point against it?
Regards,
--
Nicolas Goaziou
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-ox-Change-default-asynchronous-export-setup.patch --]
[-- Type: text/x-diff, Size: 2853 bytes --]
From 993105a2bdf70a146c302e10884da1f0de406a65 Mon Sep 17 00:00:00 2001
From: Nicolas Goaziou <n.goaziou@gmail.com>
Date: Mon, 28 Oct 2013 18:56:04 +0100
Subject: [PATCH] ox: Change default asynchronous export setup
* lisp/ox.el (org-export-async-init-file): Change default value and
allowed values.
(org-export-async-start): Apply change to the variable.
---
lisp/ox.el | 37 +++++++++++++++++++++++++------------
1 file changed, 25 insertions(+), 12 deletions(-)
diff --git a/lisp/ox.el b/lisp/ox.el
index 141abc4..20d7107 100644
--- a/lisp/ox.el
+++ b/lisp/ox.el
@@ -839,15 +839,23 @@ automatically. But you can retrieve them with \\[org-export-stack]."
:package-version '(Org . "8.0")
:type 'boolean)
-(defcustom org-export-async-init-file user-init-file
+(defcustom org-export-async-init-file nil
"File used to initialize external export process.
-Value must be an absolute file name. It defaults to user's
-initialization file. Though, a specific configuration makes the
-process faster and the export more portable."
+
+Value must be either nil or an absolute file name. When nil, the
+external process is launched like a regular Emacs session,
+loading user's initialization file and any site specific
+configuration. If a file is provided, it, and only it, is loaded
+at start-up.
+
+Therefore, using a specific configuration makes the process to
+load faster and the export more portable."
:group 'org-export-general
:version "24.4"
- :package-version '(Org . "8.0")
- :type '(file :must-match t))
+ :package-version '(Org . "8.3")
+ :type '(choice
+ (const :tag "Regular startup" nil)
+ (file :tag "Specific start-up file" :must-match t)))
(defcustom org-export-dispatch-use-expert-ui nil
"Non-nil means using a non-intrusive `org-export-dispatch'.
@@ -5552,12 +5560,17 @@ and `org-export-to-file' for more specialized functions."
(let* ((process-connection-type nil)
(,proc-buffer (generate-new-buffer-name "*Org Export Process*"))
(,process
- (start-process
- "org-export-process" ,proc-buffer
- (expand-file-name invocation-name invocation-directory)
- "-Q" "--batch"
- "-l" org-export-async-init-file
- "-l" ,temp-file)))
+ (apply
+ #'start-process
+ (append
+ (list "org-export-process"
+ ,proc-buffer
+ (expand-file-name invocation-name invocation-directory)
+ "--batch")
+ (if org-export-async-init-file
+ (list "-Q" "-l" org-export-async-init-file)
+ (list "-l" user-init-file))
+ (list "-l" ,temp-file)))))
;; Register running process in stack.
(org-export-add-to-stack (get-buffer ,proc-buffer) nil ,process)
;; Set-up sentinel in order to catch results.
--
1.8.4.2
next prev parent reply other threads:[~2013-10-30 10:00 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-27 9:35 [RFC] Slight change to asynchronous export Nicolas Goaziou
2013-10-28 8:46 ` Sebastien Vauban
2013-10-28 9:04 ` Nicolas Goaziou
2013-10-29 10:43 ` Rasmus
2013-10-29 13:27 ` Nicolas Goaziou
2013-10-28 15:04 ` Carsten Dominik
2013-10-28 15:07 ` Aaron Ecay
2013-10-28 17:18 ` Nicolas Goaziou
2013-10-28 17:22 ` Aaron Ecay
2013-10-29 10:50 ` Rasmus
2013-10-28 17:39 ` Achim Gratz
2013-10-29 8:35 ` Nicolas Goaziou
2013-10-29 17:42 ` Rick Frankel
2013-10-30 8:27 ` Sebastien Vauban
2013-10-30 10:00 ` Nicolas Goaziou [this message]
2013-10-30 13:50 ` Rick Frankel
2013-10-31 10:23 ` Nicolas Goaziou
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=8738njaxj3.fsf@gmail.com \
--to=n.goaziou@gmail.com \
--cc=Stromeko@nexgo.de \
--cc=emacs-orgmode@gnu.org \
--cc=rick@rickster.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).