Hi, guys, This is an expression of dismay of the current practices I see developing. You may or may not agree, but at least consider the long term implications.
One of my pet peeves is the lack of formatting on autogenerated files. Microsoft is one of the worst perpetrators, but the poor practice has begun to invade all forms of programs and designs. Lack of formatting makes sorting issues not just difficult, but as programs are copied, and dead code fragments are left in but commented out, the code gets really messed up. If a code fragment is dead, remove it. If a setting is not used, remove it. Leaving these things in place is poor practice, unprofessional and collects garbage. HTML code is bad to begin with due to its fundamental formatting, but leaving out linefeeds, tabs, and spaces just makes it worse. Would you like reading a book with no punctuation, no paragraphs, and lack of structure? Yet I see lots of that kind of documentation, and even more code like that. This is not furthering the profession, nor is it helpful. With that said, here is a snippet from the gconf stuff for evolution: Directly from the file: ------------------------------------------------------------------------------ <?xml version="1.0"?> <group uid="1162801071.10728.17@localhost.localdomain" name="On This Computer" base_uri="local:" readonly="no"><source uid="1162801071.10728.18@localhost.localdomain" name="Personal" uri="file:///home/lesh/.evolution/addressbook/local/system" relative_uri="system"><properties><property name="pilot-sync" value="true"/><property name="use-in-contacts-calendar" value="0"/></properties></source><source uid="1163129951.18548.0@localhost.localdomain" name="Personal2" relative_uri="1163129951.18548.0@localhost.localdomain"><properties><property name="completion" value="true"/><property name="remember_password" value="false"/></properties></source></group> ------------------------------------------------------------------------------ How many of you can read and understand this bit of code? I especially dislike the ##########.#####.#@localhost.localdomain filename. This has no significance to the job being accomplished. As much as I rail against "self documenting code", this is just beyond useless. It smacks of trying to use obfuscation for security, which has been proven over and over to not aid security. Other than that it has no value, no significance and adds no real value to the process being described. But putting an entire page of a book of code in one line is unforgivable. I write converters between systems, changing hardware, software platforms and instrument capabilities. I would be embarrassed to show something like this to one of my customers, moreover it would probably result in my never being hired again. Long ago, when BASIC first raised its head, this kind of stuff was done because the systems were slow to interpret text, so leaving out punctuation, spacing, comments and so forth made the program run faster. This may be true for HTML code, but todays computers run at least 1,200,000,000 times faster than they did back then. This kind of work is horrible to support. Cleaned up just a bit, the use of the code becomes clearer. But it also uses two forms of HTML controls, both the <header>...</header> and the <header />. Both are of course legal and useful in some contexts, but it is usually preferable to maintain consistency. Check out how it looks with just a bit of formatting. I don't know if the formatted code will run or not, but if not, the interpreter needs a visit. Good practices should always help make the code understandable. Edited ----------------------------------------------------------------------------------- <?xml version="1.0"?> <group uid="1162801071.10728.17@localhost.localdomain" name="On This Computer" base_uri="local:" readonly="no"> <source uid="1162801071.10728.18@localhost.localdomain" name="Personal" uri="file:///home/lesh/.evolution/addressbook/local/system" relative_uri="system"> <properties> <property name="pilot-sync" value="true"/> <property name="use-in-contacts-calendar" value="0"/> </properties> </source> <source uid="1163129951.18548.0@localhost.localdomain" name="Personal2" relative_uri="1163129951.18548.0@localhost.localdomain"> <properties> <property name="completion" value="true"/> <property name="remember_password" value="false"/> </properties> </source> </group> --------------------------------------------------------------------------------------------- If you read all the way to here, thank you. If you disagree, that is OK, but remember that one day you will have to support code written in one block that is over 3000 characters long (I have already seen that on some web pages.) Regards, Les H _______________________________________________ evolution-list mailing list evolution-list@gnome.org To change your list options or unsubscribe, visit ... http://mail.gnome.org/mailman/listinfo/evolution-list