Adding the script in the hint text is a bit too much, so I put it online for you guys to download here. Please read the page before downloading, as you also need the 24U Appearance OSAX 2.1 library.
[robg adds: The script is too long to easily attach to this hint, so I've also mirrored it in the macosxhints' downloads section: Move to Named Folders [30KB].]

