Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

I've got a groundbreaking idea.

Name: Anonymous 2008-09-06 14:08

What if, instead of just plain XML, or any other markup language for that matter, we build an executable file that upon execution prints whatever is stored in the file? That way we can run like:

$ ./index.xml

And then see the output of the file on stdout. Since the file is binary, we can't just edit it with emacs, so we have to make the file edit itself! For example:

$ ./index.xml --edit-node 3 --set-attribute name=haskell

What do you guys think, /prog/rammers?

Name: Anonymous 2008-09-06 17:29

>>1
How about we use a LISP program to store the actual data in such a way that running it will produce the XML document? Like this

(doctype whatever)
(node
  (subnode (list ('attribute value) ('another other)))
;node)

results:
<?DOCTYPE ...>
<node>
  <subnode attribute=value another=other/>
</node>

Suddenly XSLT looks like a dirty hack.

Name: Anonymous 2008-09-07 6:57

>>12
My idea is that it will be far easier to manipulate a lisp list with a LISP program and then turn that into XML than using XSLT for the same purpose. The added benefit is that it will be far more readable by humans and will have more capabilities. I am of course blissfully ignorant of the rationale behind XSLT. That "thing" mutated into a list processing language a long time ago.
>>13
Thanks but I have to go back to reading my SICP.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List