Re: [dev] [st] [patch] Cleanup config.def.h, eliminate mappedkeys, simplify matching.
Sorry for the delay, but I am very busy lately :S. > Note that match() is used in four places, so I can't merge it into kmap(). You are right and I suck. When I wrote this function it was a part of kmap which became too much complex, so I put the code in a new function, and I didn't know other guys had used it. > I've done this, but I'm not sure it reads as well. The existing > version first checks the *kp fields because if they are zero, the is > no need to peek at term.mode. Uhmmm, it is true. We have to be careful with these code, so let me see with more time if there is some problem or not with this new version. And thank you for your efforts :) -- Roberto E. Vargas Caballero ___ 'Write programs that do one thing and do it well. Write programs to work together. Write programs to handle text streams, because that is a universal interface' (Doug McIlroy) In Other Words - Don't design like polkit or systemd ___
Re: [dev] Some thoughts about XML
2013/10/24, Alexander S. : > Personally, I'm okay with XML, and feel like Archangel Uriel, may he > rest in peace, was slightly exaggerating. XSLT may be horrid, though, > and XML is maybe *too* verbose, but the idea of having a structure as > a building block is totally okay with me. There is expat parser, and > who needs anything else. > Using XML for simple, non-hierarchical config files is just plain > wrong, not because XML is bad, but because it is misapplied. Using XML > for storing Rhythmbox music database is wrong for the same reason. XML > is for documents. I think Russ Cox said it very well[1]: Mapping between XML elements and data structures is inherently flawed: an XML element is an order-dependent collection of anonymous values, while a data structure is an order-independent collection of named values. See [...] json for a textual representation more suitable to data structures. 1 - http://tip.golang.org/src/pkg/encoding/xml/read.go?s=257:579#L7
Re: [dev] Some thoughts about XML
2013/10/24 Charlie Kester : > So don't use it as a markup language. > > As far as I know, it was never claimed to be fit for that purpose. Um. 2013/10/23 Mihail Zenkov : > It not mention good xml alternative: TOML > https://github.com/mojombo/toml 1) TOML is basically .ini on steroids, 2) XML is a markup language, 3) anything that claims to be "xml alternative" ought to be a markup language. Personally, I'm okay with XML, and feel like Archangel Uriel, may he rest in peace, was slightly exaggerating. XSLT may be horrid, though, and XML is maybe *too* verbose, but the idea of having a structure as a building block is totally okay with me. There is expat parser, and who needs anything else. Using XML for simple, non-hierarchical config files is just plain wrong, not because XML is bad, but because it is misapplied. Using XML for storing Rhythmbox music database is wrong for the same reason. XML is for documents.
Re: [dev] Some thoughts about XML
2013/10/24 Samuel Holland : > [body] > content="%ol%%p%" > [ol] > style="list-style-type: decimal" > content="%li.1%%li.2%%li.3" > [li] > style="display: list-item" > content1="Lack of proper hierarchy, for one;" > content2="Lack of proper heterogeneous containers, for two;" > content3="%b%:\nlack of multiline strings." > [b] > style="font-weight: bold" > content="The most important one" > [p] > style="display: block" > content="Try to express something as simple as %i% (which is\nrather trivial > HTML snippet) in .ini format." > [i] > style="font-style: italic" > content="my answer" I didn't say it was impossible, mind you. I just said it would be the opposite of okay. Thanks for clearly demonstating my point :).
Re: [dev] Some thoughts about XML
Chris Down wrote: >On 2013-10-24 01:04, Samuel Holland wrote: >> [body] >> content="%ol%%p%" >> [ol] >> style="list-style-type: decimal" >> content="%li.1%%li.2%%li.3" >> [li] >> style="display: list-item" >> content1="Lack of proper hierarchy, for one;" >> content2="Lack of proper heterogeneous containers, for two;" >> content3="%b%:\nlack of multiline strings." >> [b] >> style="font-weight: bold" >> content="The most important one" >> [p] >> style="display: block" >> content="Try to express something as simple as %i% (which is\nrather >trivial HTML snippet) in .ini format." >> [i] >> style="font-style: italic" >> content="my answer" > >I'm hoping this is devil's advocate, this is the worst thing I've ever >seen. Yes, it was. The variable substitution is entirely made up, but what's worse is that almost every line of the Wikipedia page starts with "some implementations..." What I have been giving thought to is a representation using JSON, where each element is an array. The first member is a CSS selector, and subsequent members are strings and more arrays. That way you keep ordering and small size, yet can still mix text and elements.
Re: [dev] misc projects
On Wed, Oct 23, 2013 at 03:46:05PM +0200, koneu wrote: > >I'm a GNU GPL guy > oh, fuck no... :P
Re: [dev] misc projects
>I'm a GNU GPL guy oh, fuck no...