From: james@... Date: 2002-07-25T09:25:56+09:00 Subject: RE: [ANN] YAML4R 0.26 > > > How about a short summary for the rest of us who have no idea what > > yaml is ... or at least a URL. > > http://www.yaml.org > > YAML is a serialization scheme that uses human-readable (and editable) > text as is representation. There is an article on XML.com about YAML, "Look Ma, No Tags" http://www.xml.com/pub/a/2002/07/24/yaml.html I've been spending less time with XML than my Magic 8-Ball (tm) lead me to expect, but have been looking at blogging & wiki software. In particular, I'm interested in "magic markup", or the implied markup that exists by convention. Wikis, for example, are smart enough to interpret linefeeds, indentation, and various simple characters as instructions to create more sophisticated markup. I was motivated to write some add-ons for Cherry Blosxom, and one of my goals was to allow people (i.e., me) to do things without thinking too much about what the software needs. For example, I wanted my site (www.jamesbritt.com) to have a sidebar, with assorted boxes for things like links, my reading list, whatever. The box content is processed much like a set of sub-blogs, but the user can define what class handles the rendering from text to HTML. I started using a config file for this, but it's too much work. Now, the code figures out what directories hold sidebar content based on a directory naming convention. Any directory that contains '.box' is assumed to be sidebar box. The contents of the directory are rendered using a default rendering class. If '.box' is followed by anything else, that is taken as the name of the class to render that particular sidebar box. Whatever comes before '.box' is the title of the box. SomeTitle.box.RenderWithThisClass So, the code uses some implied markup, allowing users to remain blissfully oblivious if they prefer. Certainly better than a separate file with boxdir=SomeTitle.box.RenderWithThisClass title= Some Title renderingClass=RenderWithThisClass (Another to look at this is that the blogging directory itself becomes the configuration file, with file and directory entries server as config entries.) Ruby makes this very easy to do. Dynamic loading of classes and method calls means any input is a potential mini-language. The next step is to improve Cherry Blosxom's parsing of the main blogging content. There's too much reliance on explict markup. I don't know if YAML will figure into this, but certainly the idea of lightweight markup is important. James Britt