Is there a mod-emacs?
  Home FAQ Contact Sign in
gnu.emacs.help only
 
Advanced search
POPULAR GROUPS

more...

gnu.emacs.help Profile…
 Up
Is there a mod-emacs?         


Author: rustom
Date: Jan 3, 2008 08:37

Just as there are mod-perl mod-python etc for apache is there
something like mod-emacs of some sort?

Context is as follows:

org mode has org-export-as-html which produces html for the
corresponding org file.

If apache could be configured to talk to emacs then when it is asked
to serve a .org file, say foo.org it could do

emacs -batch -eval '(org-export-as-html foo.org)'

and serve the resulting html.
8 Comments
Re: Is there a mod-emacs?         


Author: Bastien
Date: Jan 3, 2008 13:06

Hi Rustom,

rustom gmail.com> writes:
> Just as there are mod-perl mod-python etc for apache is there
> something like mod-emacs of some sort?

so far I've only met mod-lisp, mod-scheme, mod-guile:

mod-lisp:

http://common-lisp.net/cgi-bin/mailman/listinfo/mod-lisp-devel
http://bc.tech.coop/blog/051219.html

mod-scheme:

http://code.google.com/p/mod-scheme/

mod-guile:

https://savannah.nongnu.org/cvs/?group=mod-guile

This latter project looks dead. I've not tested any of these solutions.
Some time ago, I set up a org->HTML online converter, but this was done
through python: the script ran an "emacs -batch" instance and the HTML
output was then opened.

I'd also be interested in more information on any mod-emacs thingy!

--
Bastien
no comments
Re: Is there a mod-emacs?         


Author: Tim X
Date: Jan 6, 2008 01:35

rustom gmail.com> writes:
> Just as there are mod-perl mod-python etc for apache is there
> something like mod-emacs of some sort?
>
> Context is as follows:
>
> org mode has org-export-as-html which produces html for the
> corresponding org file.
>
> If apache could be configured to talk to emacs then when it is asked
> to serve a .org file, say foo.org it could do
>
> emacs -batch -eval '(org-export-as-html foo.org)'
>
> and serve the resulting html.

There is an emacs elisp httpd server (at least there use to be one), but no
mod_emacs that I'm aware of.
Show full article (1.18Kb)
no comments
Re: Is there a mod-emacs?         


Author: thorne
Date: Jan 6, 2008 02:01

Tim X writes:
> There is an emacs elisp httpd server (at least there use to be one), but no
> mod_emacs that I'm aware of.

I wonder about the security of such a thing. But it would be fun to try
getting it to serve my personal web page.
> Of course, this is a rather resource expensive way of serving a few pages -
> you would always have to have an emacs image loaded or accept fairly slow
> responses (depending on machine/resoruces etc).
>
> I think a better solution would be to add a hook to the org mode save
> function that does an automatic export as html whenever the org file is
> updated. The pages can then be served by a regular httpd process and as a
> new export is done whenever the org file is saved, the pages will always be
> up-to-date (provided they are edited by emacs of course).

True, but the fun would be in using Emacs to do dynamically generated
pages. Emacs could be the world's slowest Web Application
Framework(tm).

--
Theron Ttlåx
no comments
Re: Is there a mod-emacs?         


Author: Tim X
Date: Jan 6, 2008 21:56

thorne timbral.net> writes:
> Tim X writes:
>
>> There is an emacs elisp httpd server (at least there use to be one), but no
>> mod_emacs that I'm aware of.
>
> I wonder about the security of such a thing...
Show full article (2.00Kb)
no comments
Re: Is there a mod-emacs?         


Author: Mathias Dahl
Date: Jan 7, 2008 08:55

Tim X writes:
> Another approach that might be interesting is to create an emacs
> lisp package for common lisp. You could then take advantage of
> mod_lisp. Not sure how you would handle the lisp1 vs lisp2
> differences

Both are Lisp2, aren't they? Maybe you thought about lexical vs
dynamical scoping?
no comments
Re: Is there a mod-emacs?         


Author: Joel J. Adamson
Date: Jan 7, 2008 11:52

Bastien altern.org> writes:
> Hi Rustom,
>
> rustom gmail.com> writes:
>
>> Just as there are mod-perl mod-python etc for apache is there
>> something like mod-emacs of some sort?
> Some time ago, I set up a org->HTML online converter, but this was done
> through python: the script ran an "emacs -batch" instance and the HTML
> output was then opened.

Good idea: this would be a great way to keep up my schedule without
ferrying my org files from machine to machine. However...

Did you get real checkboxes on org export to html? I've been
considering trying to patch the code to do that. My currently loaded
version of org-mode produces just "- [ ]" instead of an html checkbox.
Is there any discussion of changing the behavior?

Joel
Show full article (0.93Kb)
no comments
Re: Is there a mod-emacs?         


Author: thorne
Date: Jan 7, 2008 13:29

jadamson@partners.org (Joel J. Adamson) writes:
> Good idea: this would be a great way to keep up my schedule without
> ferrying my org files from machine to machine. However...
>
> Did you get real checkboxes on org export to html? I've been
> considering trying to patch the code to do that. My currently loaded
> version of org-mode produces just "- [ ]" instead of an html checkbox.
> Is there any discussion of changing the behavior?

Actually a generalized html generation library (or xml) might be a nice
thing for Emacs (maybe it already has one...?). I am not sure about Org
mode, but i am pretty sure Emacs Muse uses regexp substitution on a
buffer to generate html--which is great (i use Muse for my web page) but
it might also be nice to have something like Common Lisp's lml2 for
creating html from lisp code. I hacked up the beginning of something
for my own use using Common Lisp macros once and it wasn't that hard to
do. The syntax ended up something like:
Show full article (1.30Kb)
no comments
Re: Is there a mod-emacs?         


Author: Joel J. Adamson
Date: Jan 8, 2008 07:56

Tim X writes:
> jadamson@partners.org (Joel J. Adamson) writes:
>
>> Bastien altern.org> writes:
>>
>>> Hi Rustom,
>>>
>>> rustom gmail.com> writes:
>>>
>>>> Just as there are mod-perl mod-python etc...
Show full article (1.70Kb)
no comments

RELATED THREADS
SubjectArticles qty Group
Re: .emacs in the Windows version of Emacsgnu.emacs.help ·