For unix-like systems (Mac OS X, Linux). A simple shell script to convert flac to lame mp3.
Install flac, lame and id3tool
#!/bin/bash
for a in *.flac
do
OUTLAME=`echo "$a" | sed s/\.flac$/.mp3/g`
ARTIST=`metaflac "$a" --show-tag=ARTIST | sed s/.*=//g`
ALBUM=`metaflac "$a" --show-tag=ALBUM | sed s/.*=//g`
TITLE=`metaflac "$a" --show-tag=TITLE | sed s/.*=//g`
GENRE=`metaflac "$a" --show-tag=GENRE | sed s/.*=//g`
TRACKNUMBER=`metaflac "$a" --show-tag=TRACKNUMBER | sed s/.*=//g`
YEAR=`metaflac "$a" --show-tag=DATE | sed s/.*=//g`
flac -c -d "$a" | lame -m j -q 0 --vbr-new -V 0 -s 44.1 - "$OUTLAME"
id3tool --set-title="$TITLE" --set-track="${TRACKNUMBER:-0}" --set-artist="$ARTIST" --set-album="$ALBUM" --set-year="$YEAR" --set-genre="${GENRE:-12}" "$OUTLAME"
done |
#!/bin/bash
for a in *.flac
do
OUTLAME=`echo "$a" | sed s/\.flac$/.mp3/g`
ARTIST=`metaflac "$a" --show-tag=ARTIST | sed s/.*=//g`
ALBUM=`metaflac "$a" --show-tag=ALBUM | sed s/.*=//g`
TITLE=`metaflac "$a" --show-tag=TITLE | sed s/.*=//g`
GENRE=`metaflac "$a" --show-tag=GENRE | sed s/.*=//g`
TRACKNUMBER=`metaflac "$a" --show-tag=TRACKNUMBER | sed s/.*=//g`
YEAR=`metaflac "$a" --show-tag=DATE | sed s/.*=//g`
flac -c -d "$a" | lame -m j -q 0 --vbr-new -V 0 -s 44.1 - "$OUTLAME"
id3tool --set-title="$TITLE" --set-track="${TRACKNUMBER:-0}" --set-artist="$ARTIST" --set-album="$ALBUM" --set-year="$YEAR" --set-genre="${GENRE:-12}" "$OUTLAME"
done
Edit: Apparently this has been done before…
http://pastebin.com/f641a9b21
You’re not crazy. Google has done it again. They made a small change to the look of their website today: the font size and buttons on the home page and search result page are larger. I suppose this shows how ingrained Google is into everyday life, how even the smallest change is noticed by millions. Just like back in May’08 when they changed their favicon.
Internet users tend to dislike change for change’s sake. There is already a userscript that reverts Google to the “classic” look. Another good example of user discontent is the launch of New Facebook, which incited much grumbling. Ultimately though, the whole thing blows over and the face of the Web is changed forever, old designs lost in the depths of the Wayback machine.
Mise à jour: Ce clavier fonctionne toujours sous OS X 10.9 Mavericks. Il se trouve dans la catégorie “Autres” des méthodes de saisie.
Update: This keyboard layout still works with OS X 10.9 Mavericks. You can find it in the “Others” category of keyboard layouts. I have also put it on github.
This used to be on my googlepages page, but apparently that’s going to be shut down, so here it is now.
clavier-cf.zip
Download from Github (updated version with  and Ô thanks to joallard)
Download, unzip and stick the two files (cf.icns and cf.keylayout) in /Library/Keyboard Layouts. Then go to System Prefs, International (Language and Text for Snow users), Input Menu and check off “Canadien Francais 0.9”. (You may need to log out and back in before the new layout appears in System Preferences).
I did NOT make this keyboard layout, I found it somewhere on the web but the original site is now gone.
Voici le clavier Canadien francais pour Mac OS X. C’est l’équivalent du clavier “Canadian French” ou Français (Canada) sous Windows. Pour installer, télécharger le fichier .zip depuis github, décompresser, et copier les deux fichiers (cf.icns et cf.keylayout) dans le dossier /Library/Keyboard Layouts.
Here is the actual keyboard layout screenshot:
(Note: the post title is C’est la rentrée, for some reason the PNG generator doesn’t take accents. Just needed to set Cufon to “Extra”)
It has now been September for almost two days. Summer’s pretty much over, and students and teachers are getting ready to hit the books. But not me. Thanks to procrastination and administrative stupidity, I didn’t manage to get through the necessary paperwork and won’t be able to head back to university until January at the earliest. I have to say though, it’s a bit of a relief not to be going back…
Today was the first day of school for us at the CSDCCS. “But wait”, you say, “it’s not Labour day yet!”. Well, effectivement, Labour day is next Monday. However our Conseil decided that September 8th is much too late to start school. Instead, it has been decided that the 2nd and 3rd will be the first two days of school, but that Friday the 4th will be a “holiday” for teachers and students. Go figure.
Anyway, today I also went downtown to visit Emma and Muna in their new apartment. They’ve got a little basement place, pretty sweet location not far from U of T campus and Chinatown. Honestly it’s a pretty sketchy-looking place, but hey, that’s part of student life right? Actually, it made me feel kind of nostalgic… I miss the sketchy places, and just hanging out, reading webcomics and such.
That’s all for now… I even tried out two new “things” in the post today; inserted some français here and there and used people’s names (gasp!). Not sure if I’ll still think these were good ideas in the morning, but whatever.
So… I just spent two hours trying to get MythTV running properly on my OpenVZ server (installed via the Proxmox VE bare-metal installer). This is starting to be a lot harder than I thought it would be…
As seen in my previous post, I installed the 2.6.26-2-openvz-amd64 kernel and headers, and compiled v4l-dvb from mercurial, and fixed a little bug with vzctl. Today, I installed the firmware files for my Hauppage HVR-1600 (see MythTV wiki page), added the Debian-multimedia repo and installed MythTV (apt-get install mythtv). Then I realized I needed X to use mythtv-setup, so for some reason I decided to install KDE 3.5. KDE installed fine (minus some missing files for the kdm theme… wonder why these aren’t included in the kdm package or a dependency…). I then proceeded to create a password for the mythtv user ($passwd mythtv as root) and then run mythtv-setup as the mythtv user. I managed to add the sources and scan for channels, but when I tried to “Watch TV”, I was told that the primary backend wasn’t running.
I tried some troubleshooting, but it’s getting kinda late and I’m lacking sleep (as you can probably tell from my grammar), so I decided to try installing a shiny new Intel Pro 1000 Desktop (82574L) PCIe x1 Ethernet card to get my server some gigabit love. Should be simple, right? Intel cards have good driver support, with the e100 and e1000 drivers, so much so that VM solutions like VMware and VirtualBox chose to emulate them as guest hardware. Well, this was not the case today. I popped the card in to a free PCIe x1 slot and powered on the PC. Link lights went on and all looked fine and dandy. But once the machine fully booted up (takes a while with all those OpenVZ containers 😉 ), ifconfig showed only the eth0 interface, which is my built-in Realtek/nForce controller. Some further probing with lspci and dmesg showed that the card is alive, but that the e1000 driver didn’t even bother to start up.
At this point, I GIVE UP for tonight. I’m cold from sitting down in the basement, tired from lack of sleep, and frustrated from uncooperative Linux servers.
No streaming TV for me tonight, but I suppose I should be glad that at least the blog is still up and running.
Which brings to mind http://xkcd.com/349/
I currently am running this blog from an OpenVZ server managed via Proxmox VE. One issue I had with this setup is that the Proxmox 1.3 installer by default comes with a relatively old kernel (2.6.24), and I want a newer kernel (>=2.6.26, so that I can use my cx18-based TV tuner). Fortunately, Proxmox is just a customized version of Debian Lenny, so I just installed the linux-image-2.6.26-2-openvz-amd64 package from apt, then ran update-initramfs -u and update-grub.
After updating the kernel, however, I was unable to start any of my virtual machines from the Proxmox Web UI. Looking at the system log showed a message about vzctl being 32-bit; problem solved by updating vzctl via apt.
Now I’m attempting to compile v4l-dvb…. fingers crossed!
hg clone http://linuxtv.org/hg/v4l-dvb
Have you been visited by a National Home Services salesman lately? These people come to your door and try to get you to sign a contract for a long-term water heater rental. You then get stuck in a 15-year contract with a high cancellation penalty. To make matters worse, these salespeople lie through their teeth. Some say water heaters last only 2-5 years, others say Direct Energy doesn’t rent water heaters… My advice is don’t buy anything sold door-to-door, unless it’s a kid selling chocolate or cookies.
Further reading: http://www.thestar.com/article/463378
So I was off work today… It was a pretty good day, just generally relaxed. Spent the day at home, then out for tea and a movie with old high school friends. I left home at around 6pm and it had just started pouring rain, with a few fantastic bolts of lightning. I walked in to the coffee shop and while i was waiting for everyone to show up, I noticed that the TV in the corner was showing CP24 news. Apparently there had been a tornado in the area of Vaughan Mills shopping centre. While we didn’t experience much more than a severe thunderstorm (and some flooding, it seems Silver City was closed), the whole experience was somewhat surreal: friends together around a coffee shop table watching news reports and amateur video footage, while fire trucks passed by outside… It was quite nice though, we talked about all kinds of things, joked about horoscopes, discussed storms…
After we had chatted for a while, we decided to go watch District 9. It was a decent movie, quite entertaining, and I thought it was pretty cool that it was set in South Africa, instead of the USA.
A few videos and pictures from the storm (not mine, unfortunately):
“Take Immediate Precautions” … lol
http://www.blogto.com/city/2009/08/massive_storm_hits_toronto_tornados_reported_across_gta/
Aaand I suppose that’s all for now.
The latest Canadian Internet star!
"Crasher Squirrel" from National Geographic