Thursday, May 20th, 2004
“For 50 years, computer programmers have been writing code. New technologies continue to emerge, develop, and mature at a rapid pace. Now there are more than 2,500 documented programming languages! O’Reilly has produced a poster called History of Programming Languages (PDF), which plots over 50 programming languages on a multi-layered, color-coded timeline.”
Here’s the Full story (and PDF) at O’reilly.. though I like the original version better. It’s also more printable.
I already printed out the History of Unix poster from the same guy. All 18 pages.
Wednesday, May 19th, 2004
If you’re familiar with Debian GNU/Linux, you probably already knew about this internet page (apt-get.org). There you can find complete lists for alternative debian package sources.
But did you also know about this one: http://www.backports.org/?
“Backports are recompiled packages from testing (mostly) and unstable (in a few cases only, e.g. security updates), so they will run without new libraries (wherever it is possible) on a stable Debian distribution. I recommend you to pick out single backports which fits your needs, and not to use all backports available here.”
Tuesday, May 18th, 2004
I’ve got this MTek K371L mini-ergonomical keyboard. It’s got 7 buttons on the top of the keyboard for automatic copy-pasting, opening files, etc. They simultate Control-O and those kind of keybindings. These are pretty Windows specific, so I always thought I couldn’t use them under Linux. On the top right of the keyboard are three other buttons: Wake, Sleep and Power. Thought I couldn’t use them either under Linux. Turns out I was wrong.
Wake / Sleep / Power keys
The three powermanagement keys give off normal key scancodes and are already bound to couple of keycodes:
- Wake: keycode: 227
- Sleep: keycode: 223
- Power:keycode: 222
If you add the following lines to a file and run the file using the command xmodmap [FILENAME]
, you’ll be able to use them in most X programs by just using some ‘Capture key’ option or by entering the keyname. Here’s the lines to add to the file:
keycode 222 = XF86PowerOff
keycode 223 = XF86Standby
keycode 227 = XF86WakeUp
Don’t worry, they won’t actually do what the keynames suggest. I’ve got the ‘Power’ key bound to my terminal locking script (using xtrlock).
Office keys
Getting the office keys to do what I want was a little tougher. Of course they already work like normal Control-O, Control-S, etc keys, but that’s not what I want to do with them. I wanted to use them to turn up and down the volume and that kind of stuff.
Turns out that those keys actually simulate the RIGHT control (Control_R) instead of the LEFT. Since I Never Ever use the RIGHT control key, I could easily rebind them to do whatever I wanted. Since I wanted each key to do something different, I had to add another modifier to the key. Not the default Control modifier, but some empty one. Here’s how you can rebind the keys. Please note that your right control key won’t work anymore if you do this:
- Find an empty modifier key. These differ on each platform it seams, so you’ll have to check for yourself which modifier is unused. I used the xkeycaps program to check out all keys on my keyboard to see what modifier was free. Turns out both mod2 and mod5 were unused. I went for Mod5 because I haven’t ever seen this modifier used before.
- Next, remove the right control key from the Control modifier list by adding this line to the xmodmap file:
remove Control = Control_R
.
- Now, add the right control key to the empty modifier by adding another line to the modmap file. In my case Mod5:
add Mod5 = Control_R
.
- You can now bind actions to the office keys at the top of the keyboard because they emulate Control_R plus some key. Since Control_R is now Mod5, programs will understand the key and you can actually use it. It’s the same as with the last step in the Wake/Sleep/Power keys section above.
I ended up with the following modmap file named: ~/.xkeys:
keycode 222 = XF86PowerOff
keycode 223 = XF86Standby
keycode 227 = XF86WakeUp
remove Control = Control_R
add Mod5 = Control_R
I now have the Office keys mapped (using WindowMaker’s Menu which allows me to bind key shortcuts to menu items) to Volume Up/Down, XMMS Next, Previous, Stop, Play, etc. I use aumix’s commandline options to set the volume higher and lower and XMMS’s commandline options to control XMMS. Pretty cool.
I’ve also added this little tip to the Tips and Tricks page under the X11 section.
Monday, May 17th, 2004
For the fun of it, I wrote an Ode to Sharky. Sharky is my server who has been the trusty keeper of all my files, sourcecode, webpages, etc for the last six years. Sometimes people laugh at Sharky’s hardware because it’s old and outdated. But Sharky still managed to perform an enormous ammount of tasks for such an ‘outdated’ computer. Check it out.
Monday, May 17th, 2004
Slashdot and OsNews both report that a new version of Inferno is Available for download. Inferno is meant to be the follow-up OS to Plan9 which, for it’s time, was pretty neat I think.
Since Inferno is licensed under a Semi-free license and it runs in a virtual machine on Linux, I decided to give it a try. Pretty neat. Check out the screenshot:

Installation was a breeze. Simply follow the instructions on the website and in the PDF. Takes about 5 minutes and consists out of downloading the neccesary tar.gz files (I downloaded Linux.tgz, inferno.tgz and utils.tgz), unpacking the shizzles, running the install script, setting your path to include the unpacked ‘bin’ dir and running it. Pretty easy as long as you follow the manual.
Too bad there aren’t any apps for it.
Sunday, May 16th, 2004
RSS, sometimes claimed to mean Really Simple Syndication and other times said to mean RDF Site Summary, is an XML format for listing new ‘items’ on, for instance, a website. Items can describe just about anything, from news items to new forum posts.
I particulary like the meaning ‘Really Simple Syndication’. When you first look at RSS it is indeed rather simplistic. It consists of a channel, which describes the source that the RSS feed applies to, and items. Items contain a title, link and optional description. Example:
<?xml version="1.0" encoding="iso-8859-1"?>
<rss version="0.91">
<channel>
<link>http://site.com</link>
<title>Site.com New Articles</title>
<description>Newest articles on Site.com</description>
<item>
<title>Site.com now supports RSS</title>
<link>http://www.site.com/rss</link>
<description>Site.com now supports RSS feeds.</description>
</item>
<item>
<title>Title</title>
<link>http://www.site.com/</link>
<description>Description</description>
</item>
</channel>
</rss>
Simple right? Wrong!
Though its purpose is extremely simple, from which it gains it power, it’s implementation and basis as a standard are a friggin’ mess. I’m currenly working on a small program which will merge various RSS feeds into a single feed whilst maintaing the correct order of new items across different newsfeeds. And boy, am I running into a LOT of problems.
A little summary to show what a mess RSS really is:
- A minimum of four different organisations are all working, or have worked, on their own RSS standard: Netscape (who originaly came up with it), UserLand (who took over from Netscape once they stopped development of RSS), the RSS-DEV working group (Purl) and Berkman Center for Internet & Society at Harvard Law School.
- None of the different organisation’s versions of RSS are compatible with eachother.
- There are a grand total of 9 incompatible versions of RSS
- The RSS 2.0 standards (one by UserLand, one by Harvard Law School) have no DTD.
- The RSS 2.0 standards have no namespace (this is possible, but ugly)
- v0.90 (by Netscape) is based on RDF (Resource Description Framework). v0.91 (netscape version) isn’t based on RDF but is plain XML. v1.0 (by RSS-DEV) is RDF based again. v2.0 …. not RDF again.
- Various versions of the standard say that item elements should occur inside the channel element. Other versions say the items should be siblings of the channel element. Writing up a simple DTD could cure this problem once and for all, but for 2.0 they couldn’t be bothered to spit out some lines to form a DTD.
- Nowhere in any RSS standard does it say if multiple channels in a single RSS feed are permitted. Sloppy. The behaviour of feedreaders is therefor unspecified.
- v0.90 and 1.0 put rediculous restraints on the number of items that may occur in a single channel, namely 15 items. Other weird constrainst apply on the allowed lengths of titles and links. Instead of simply stating that a link element contains an URL/URI, they specify that it can only contain http:// and ftp:// URL’s.
- v0.9 (and possibly 1.0) didn’t allow the use of namespaces. Other versions suddenly did allow namespaces. Why allow namespaces in such a simple standard? Seems like asking for incompatibilities to me. It’s the HTML browser war all over again. But the best part is that people are totally ignoring the fact that 0.9 doesn’t allow namespaces and are doing it anyway. I can’t blame them either. They probably didn’t know what to do anymore either.
- Some versions of the RSS standard define entities for things like , others don’t. In one DTD they simply forgot to add the entity definitions. Some versions of RSS don’t even have a DTD so the entities can’t be used. You’ll be stuck with using � styled XML entities.
- RSS 2.0 standard allows the use of HTML tags inside RSS elements WITHOUT HAVING TO DEFINE A NAMESPACE! That’s brilliant. Do they even have a clue about that kind of terrible parsing errors this is going to cause? Well now that I think of it… none. Since there isn’t a DTD the feeds can never be validated so all kinds of weird tags are indeed allowed. Way to define a standard! “Let’s not think about how to do it the good-old-w3c-xml-way, let’s just not define a DTD. Good thinking guys.
- RSS 2.0, since it doesn’t have a DTD, has no entities other than the default XML ones (e, etc). But, in their own examples supplied with the standard they just use all kinds of unidentified entities. Ouch. Clearly done by super XML experts *cough*.
- Due to different organisations all putting out their own versions of the specs, v1.0 PREDATES v0.92. Time and space do not exist anymore, we’re going back in time!
- Specifications for the standards are scattered all over the web (which is the reason I’m not linking to any of them), including versions by the same authoring groups.
And this is just a short list of all the (possible) problems I’ve found while trying to implement a simple RSS parser which Just Works™. There’s more where that came from. Disclaimer: The list above might contain errors. I haven’t done extensive research into all the problems, but I do know it’s a pretty big mess.
I’ve composed a little table to show the mess in a clear form:
Version |
Creator |
RDF? |
Items inside Channel? |
Summary of problems |
v0.90 |
Netscape |
Yes |
No |
Idiotic limitations |
v0.91 |
Netscape |
No |
Yes |
Two versions |
v0.91 |
Userland |
No |
Yes |
Two versions |
v0.92 |
Userland |
No |
Yes |
HTML allowed w/h NS, no NS |
v1.0 |
RSS-DEV |
Yes |
No |
HTML allowed w/h NS |
v2.0 |
Userland |
No |
Yes |
No DTD, No NS |
v2.0 |
Harvard |
No |
Yes |
No DTD, No NS, same as Userland’s, different copyright. |
Really Simple Syndication kids!
But.. other than the small problems listed above, RSS (or at least the idea behind it) rocks. :) My merger (python) will be released soon.
Here’s some links to various rants about RSS:
diveintomark.com,
XML.com.
Okay and now to cover my ass:
- Userland and Harvard blah’s v2.0 may be the same standard. Only their copyright statements differ from eachother, so I’m not sure. I think their in on this together or something. Probably a conspiracy.
- Various sources on the internet on which I based the information in this article may not have gotten it right either. It’s a real mess, so it’s kinda hard to find out how exactally all these pieces fit together to form the big picture.
- I’m no XML expert, so some statements I’ve made might be wrong.
- Don’t trust the information in this article. I’m sure I am wrong. Never trust anything written on the Web anyway.
E-mail me for corrections.
Thursday, May 13th, 2004
Paul Graham talks about how good programming design relates to beauty and therefor taste.
In the article he compares many different fields like mathmatics, physics and art with program design. He talks about what they have in common and why some of it works and some of it doesn’t. Interesting ‘programming is art’ article.
Tuesday, May 11th, 2004
Linux Weekly News writes:
“Novell has sent out a press release pre-announcing Evolution 2.0 (which will be available in the third quarter). Perhaps more interesting is the announcement that the proprietary Connector product, which interfaces Evolution with Microsoft Exchange servers, will be integrated with Evolution and released under the GPL.”
Go Novel! Go Novel!
Tuesday, May 11th, 2004
Some years ago me and some co-workers aquired a cheap mini keyboard through Benjamin. It’s a great keyboard and a whole lot smaller than normale keyboard since it doesn’t have that completely useless space inbetween the normal keys and the function keys and it’s missing the never-used numeric pad. Its dimensions are only 32x16cm and that saves a lot of desktop space.
Unfortunatelly we’ve never been able to find another place where we could buy them. Since the first one came from a computer fare and we didn’t know the name of the computer store that sold it to us we couldn’t buy it from the original source. The thing didn’t have a brandname on it, so it was also impossible to find another reseller.
But some googling brought up this:
Apparently it’s called an MTek K371L ErgoCompact Desktop. In the Netherlands you can buy one from Computer Home. There’s three different version:
- Mtek K371 MINI-KEYBOARD MET OFF KEY US ZILVER/ZWART : €22,61
- Mtek K371 MINI-KEYBOARD MET OFF KEY USB/PS/2 Combo: €17,85
- Mtek K371 ps/2 MINI-KEYBOARD MET OFF key: €16,66
The weird thing is, there’s another keyboard just like the MTek one. It’s called the ErgoStars Aquarius minikeyboard, and it’s priced at €55,-!! That’s more than three times as expensive! Perhaps it’s more ergonomical, but I doubt it’s any different from the one I’ve got.
Update: Also check out this post to find out how to use the office and power keys under linux.
Saturday, May 8th, 2004
I’m doubting Python’s stability:
Traceback (most recent call last):
File "./bla.py", line 76, in ?
print rssItemsLastSeen
NameError: name 'rssItemsLastSeen' is not defined
Segmentation fault
I wasn’t even doing anything out of the ordinary.. Just fiddling around a bit with lists and dictionaries. Nice going python! ;-)
The text of all posts on this blog, unless specificly mentioned otherwise, are licensed under this license.