Emacs on Windows 7, and setting up ColorTheme

Wanting Emacs on Windows 7?  The install is easy.  There is nice but old instructions over at Installing Emacs on Windows 95/98/2K/NT/ME/XP/Vista/Windows 7.  Here's what I did (I used an administrator account.  YMMV).
  1. I wanted emacs in C:\Program Files (x86)\emacs, so I created that folder first
  2. Go here to get the latest emacs version. I got emacs-23.2-bin-i386.zip
  3. Unzip that file and dump its contents into C:\Program Files (x86)\emacs
  4. In Windows Explorer, open C:\Program Files (x86)\emacs\bin, then double click on runemacs.exe
  5. Yay! You have emacs running.  You may wish to add runemacs.exe to your Start menu (drag and drop it there)
Now I copied over from my Ubuntu Linux my .emacs and .emacs.d.  But where to place it?  If you follow Art Lee's instruction step 6, you can control where you want to place those files using the HOME Environment Variable (set in the Windows Control Panel).

On the other hand, why bother?  Especially if you are not running emacs as an administrator.  By default, the HOME will apparently be set as C:\Users\your_user_name\AppData\Roaming anyway, so copy .emacs and .emacs.d into that directory.

Unfortunately for me, coming from Ubuntu, I had ColorTheme installed via apt-get, so it wasn't contained in my .emacs.d.  I have to reinstall that now...


Using UUID in fstab on Ubuntu

Unfortunately for me, I have four internal hard drives and a DVD drive on a motherboard that only has four SATA connections.  So from time to time, I do a musical chairs game moving wires around.

Then I started up Ubuntu and it complained it couldn't mount one of my drives.  I checked it and it was a good running drive, so what's wrong?  It turns out I had an fstab entry for a /dev/sdb1 for one of my drives that was using ext3, but after swapping some wires around, /dev/sdb1 mapped to my other drive that was using ext4.  Or maybe it was the other way around.

Anyway, I noticed my primary boot and swap volumes were listed in fstab using UUIDs, so I figured it would be helpful to list my other drives using UUID as well so that they won't be sensitive to the wire swapping that happens from time to time.

How to find out the UUID of the drives?  A quick ls -l /dev/disk/by-uuid/ works, or else try sudo blkid.

More info here: How to find your UUID’s for devices in Ubuntu (and other Debian based distros)

Funny thing, someone else did the exact opposite years ago, switching UUIDs back to /dev/paths.  Maybe UUIDs back then were problematic, but I'm glad Ubuntu stuck with it because it's sure convenient for me nowadays.


Mapping caps lock to control key in Windows 7

Turns out it's really easy to map the caps lock key to the control key in Windows 7.  Instructions are everywhere, but these two were useful for me:
Despite the link title, the first link is best as it includes the registry changes needed saved into files you can download and import into the registry.

Oh, and the Registry Editor can be opened from the Start Menu's Search box as regedit.exe.


Manipulative Pricing? FutureShop, WestJet, Chapters, and NCIX

Or perhaps this post should be called: "how not to manipulate price and avoid appearing slimy to customers."

As Canadians who fly a fair bit know, WestJet and Air Canada used to have pretty crazy seat sales, matching each other's prices, prices that change sometimes day to day, etc. Then recently, WestJet said they were getting rid of seat sales, citing customers being "frustrated at the unpredictability of fares" (WestJet scraps seat sales, reduces everyday prices).

That's one way to put it.  Another way would be that customers are frustrated at what appears as arbitrary manipulation of fares.

Skip over to FutureShop, where I was looking at Kaspersky Internet Security 2011. On their web site, they are selling it at $39.99 (which even qualifies for free shipping). Later, I find myself walking into their real-world store and find them selling it on the shelf at around $79.99, or around the price that it sells for from Kaspersky's online store. There is no obvious explanation that the price in the real-world store is going to be different than the price in the online store (and by that much!).

To me, that appears as arbitrary manipulation of the product's price.


Windows 7 loves to eat GRUB bootloader

Now I know why Grub is called Grub — Windows loves to eat it up every time it makes an update.  I've had to reinstall Grub about five times this week...

Two notes: my instructions from before works fine for my system.  But remember to unplug external USB drives other than the USB boot-up thumbdrive (or SD card in my case).

umm... and don't delete the Ubuntu linux boot-up drive once you've created it.  You'll need it whenever Windows updates itself and destroys Grub in the process.  Frustrating!


Firefox add-ons I like

Since I use a number of different computers with different user profiles and such, I have Firefox with separate profiles everywhere.  Maybe I should figure out how to synchronize them or something, but whatever, here's a list of what I like to remind myself next time I have to install Firefox anew:

  • Adblock Plus — for blocking ads
  • HTTPS-Everywhere — because I like to encourage web site operators to use HTTPS to secure everything, whether it's really necessary or not
  • BetterPrivacy — controls cookies
  • CookieMonster — more cookie management
  • RefControl — controlling the HTTP referer sent
  • SkipScreen — skips gateway pages from various file storage/download sites
  • Stop Autoplay — stop autoplay of embedded music and movies
  • Master Password Timeout — locks the FireFox password archive automatically
  • BlockSite — for blocking the sites I like to go to for procrastination purposes. It's amazing how just that little extra effort required to go to those sites can stop me from wasting time. It's almost like typing in "news.ycombinator.com" is just a reflex, and if something is there to block that reflex the amount of procrastination drops significantly!
  • Download Statusbar — is a way better way to display current downloads
  • FireGestures —mouse gestures control of FireFox
  • FEBE — for backing up FireFox settings and plug-ins
Teaching Web Design
  • Html Validator — validates HTML web pages. Great for use when marking students web pages!
  • TinEye Reverse Image Search — convenient access to TinEye for finding where images came from.  Great for checking to see if students submitted web pages with images they copied without permission from elsewhere
While I'm here, this new TrueType font for Mac, Windows, and Linux, looks cool for programming purposes, called "Anonymous Pro". This has nothing to do with Firefox, but I have nowhere else to write this down. :)

(edit: added more ...)