all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Phil Jackson <phil@shellarchive.co.uk>
To: emacs-devel@gnu.org
Subject: xmlgen.el: inclusion?
Date: Mon, 01 Sep 2008 15:43:57 +0100	[thread overview]
Message-ID: <87ljycgc42.fsf@shellarchive.co.uk> (raw)

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

Hi,

Correct me if emacs already has this functionality, but...

I knocked up an xml generation (xmlgen, I have no imagination) tool that
I think may be handy enough for inclusion. I only use it for basic
stuff, but find I use it a lot:
    
    (xmlgen
     '(html
       (head (title "Hello"))
       (body :id "anid" :class "aclass"
        (h1 "Hello"))))
    
    =>
    
    "<html>
      <head>
        <title>Hello</title>
      </head>
    
      <body id=\"anid\" class=\"aclass\">
        <h1>Hello</h1>
      </body>
    </html>"

(The output isn't indented like that. It'll be on one line.)

I expect there are a few modules in emacs itself that might benefit from
it making big `format' statements more manageable (erm, and slower).


[-- Attachment #2: xmlgen.el --]
[-- Type: application/emacs-lisp, Size: 4287 bytes --]

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



Cheers,
Phil
-- 
 Philip Jackson
 http://www.shellarchive.co.uk

                 reply	other threads:[~2008-09-01 14:43 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

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

  git send-email \
    --in-reply-to=87ljycgc42.fsf@shellarchive.co.uk \
    --to=phil@shellarchive.co.uk \
    --cc=emacs-devel@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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.