Philippe Gauthier

June 2008 Archives

Owww! It's hot in here!

| | Comments (0) | TrackBacks (0)
I checked the current weather on the Web to make sure that the very high humidity was not a product of my imagination. Some clothes from this morning's laundry have been hanged but at this rate they are not even close to be dry until tomorrow. Environment Canada confirms: the air is over 90 % saturated with humidity and humidex is 29.

What really is humidex? I knew that it was supposed to represent the perceived temperature, but I clicked on the link for more information. It finally reveals that the formula does not have a strong physical basis. This empirical formula essentially is H = T + (e − 10), where, T is the temperature in degrees Celsius and e is the vapor pressure in mbar calculated from the dew point.

chilldex.pngThe site also offers a program named Chilldex to calculate the humidex and relative humidity based on the temperature and the dew point, but only if you run Windows... Ha! Let's use our mad Python skillz and create our own tools! Don't hesitate to modify and share.

humidex.py

(It will also spare you having to look at a picture of mounted police...)

Rsync on Windows sanity

| | Comments (0) | TrackBacks (0)
While I was trying to synchronize a music library between the Linux host and a Windows machine by using rsync (cwRsync, to be exact), I realized that most of of the directory and file names were scrambled, or displayed long strings of question mark characters. There is a --iconv flag to rsync I though of using so I started to search the Web for the details. Some mailing list from a year ago suggested using a Unicode-aware version of the Cygwin DLL. The site seems to be up-to-date with the current Cygwin thus I downloaded the new library and moved it to the cwRsync bin directory. It works! You can download the patched Cygwin library here.

Now the remaining problems are synchronizing files and directories with characters that the archaic Windows shell does not accept and Cygwin still doesn't process directories with more than 260 characters...

Edit: The limitation of 260 characters exists because Cygwin attempts to support the old non Unicode-aware versions of Windows. One day this may change. Also, there is a branch in rsync code that would allow the characters in the file names to be translated. A patched binary of rsync is available on the receiver side, but I don't have enough motivation to build a patched version on the Linux server side right now. Shame on Windows for bad POSIX support...

About this Archive

This page is an archive of entries from June 2008 listed from newest to oldest.

April 2008 is the previous archive.

August 2008 is the next archive.

Find recent content on the main index or look in the archives to find all content.

  • Subscribe to feed

Contact me