Firefox’s Stylish plugin rocks January 7, 2007 at 7:58 pm

[ Watching:

“Titus – Seasons 1 & 2” (Kevin Sullivan, Howard Murray, Michael Lessac, Robert Berlinger) ]

I read a lot of blogs, and I find that a lot of them seem to think it’s cool to use really narrow columns to display their text… I guess they want to appear like a newspaper or something. While it’s not a big deal reading text like that in a newspaper, I find it extremely annoying annoying when reading websites. This wouldn’t be a big deal if the site admins would set widths with percentages so that the text resizes with the window size, but too many of them use hard-coded pixel sizes instead. Here’s an example of a recent site I visited that was just way too damn narrow.

Stylishbefore-1

No matter how wide you make your browser, the text stays as it is. Make the fonts bigger and it gets worse… less and less words on each line.

So I found and installed the Stylish add-on and gave it a shot. Does exactly what I want. Only thing that sucks is you need to check the source of the page and set overrides for the css tags the site uses, but it works.

Here’s the same site with the overrides I did:

Stylishafter

Much, much easier to read. The overrides I wrote look like:

@-moz-document domain(thesitesdomain.com) {
#outer-wrapper { width: 95% ! important; }
#main-wrapper { width: 80% ! important; }
}

Man I love Firefox and how extensible it is.

BTW, if you happen to recognize this as your site… take the advice, change your lame, narrow columns into something easier to read.

Get string from phone for iSync November 13, 2006 at 10:21 am

Apparently the software update for the Sprint V3m last week changd the string the phone sends, and so my previous post didn’t work for everyone. In fact, I tried re-doing my steps again to make sure, and found I couldn’t add back my own phone anymore because I’d updated the software (so if it was added to iSync before the update, iSync continued to work even with the updated string).

For those that haven’t seen, the new string is:
<string>Motorola CE, Copyright 2000+Motorola V3m-Sprint Phone</string>

I wrote up a quick shell script that will help you get the string from any V3* razr now (and change the grep for v3 to anything else, like k1 to get other model’s strings).

Script is getbtstring.sh For those not all that unix/Terminal savy.. save to your home directory, open a terminal, run:
chmod +x ./getbtstring.sh
./getbtstring.sh

I used sudo to do the few things that require root access, so just type in your password and it should work as is… it’ll pause and tell you to open iSync and try to add the phone, after you get the “iSync does not support his phone” hit return in the terminal, and it’ll print out what the string should likely be. it’ll also print out the raw data that you can share with me or others out there if the <string> bit doesn’t work.

For the REALLY poor terminal people.. you can update the file with the following steps:
(Note that \n means hit return)
1. Save the MetaClasses.plist file with the proper string in your homedir as MetaClasses.plist
2. run: vim /Applications/iSync.app/Contents/PlugIns/ApplePhoneConduit.syncdevice/Contents/PlugIns/PhoneModelsSync.phoneplugin/Contents/Resources/MetaClasses.plist
3. Press the ‘j’ key 3 times and the cursor should be on the first <dict> in the file…
4. Press the ‘o’ key and you should see “– INSERT –” on the bottom of the terminal.
5. Press the ‘esc’ key and the “– INSERT –” should go away.
6. Press the following keys in order: :set noai\n
7. Press the following keys in order: :r /Users/<your username>/MetaClasses.plist
\n
You should now see the updated V3m part added to the file.
8. Press the following keys in order: :wq\n
The file should now have saved and quit.

In #7 above, replace <your username> with your username on the mac… if you’re not sure what it is, on the terminal command line, type id and hit return.. it’ll show your name.. mine is mmarion, id for me shows:
uid=501(mmarion) gid=501(mmarion) groups=501(mmarion), 81(appserveradm), 79(appserverusr), 80(admin)

You might need to reboot now (or try killing the SyncServer process if you know how).. open iSync again and try adding the phone again.

Update (11/16/2006 2:32PM): Oops.. guess I can’t link inside comments… here’s the getbtstring2.sh file for people.

Update (9/27/2008): Anyone that asked about the script with Leopard… download the script again (getbtstring.sh) and give it another shot. Unfortunately I can’t really test it because I have completely downed the Apple Kool-aid and got an iPhone 3G a month or so ago.. and can’t find the RAZR.. I know it’s still around here somewhere, but I’m not sure where. :-/ If it doesn’t work, Mail me the /tmp/blued.trace file the script outputs and I’ll see if I can get how it’s dumping the info from dtruss. It should be in there.. just might be different.

Update (minutes after last): Apparently Apple supports the V3m now so the above is likely unecessary anymore.

Getting iSync to work with a new Sprint Motorla RAZR V3m November 8, 2006 at 1:31 pm

[ Listening: Finally Woken from the album “Finally Woken” by Jem ]

So I exchanged my new Samsung A900 in for a RAZR, in the hopes of using iSync to sync my calendar and address books over bluetooth. Wasn’t too happy to find that iSync gave the “Device is not supported by iSync” message when I tried to add the device. I however, am not quick to give up on tech things like this and figured I might be able to get it working myself. I saw hits on the net of people using V3m phone from other carriers, often requiring direct editing of files in the iSync.app tree itself.

Basing changes on this thread about the KRZR K1m I changed the MetaClasses.plist file on my MacBookPro… but still couldn’t get iSync to recognize the device.

I figured that the strings used to recognize the device were likely wrong, and needed to figure out my phone’s strings… to do this, I used the ktrace and kdump commands to trace the blued process on the mac when trying to add the phone again. Aha.. I found things that looked helpful:

manzana:~ mmarion$ egrep 'GMM:|GMI:' blued.txt | grep -i motorola | sort -u
+GMI: Motorola CE, Copyright 2000\r
+GMM: Motorola NC-V3m Phone\r

Now we’re getting somewhere… (don’t ask me what gmi and gmm are.. I don’t know, I just looked for things that were in the MetaClasses.plist file and might be related). Anyone else that has a newer phone/carrier’s model that isn’t being recognized yet.. this will probably work for you too (finding the strings your phone is using that is.. not the exact strings I found).

So I added a new <string> line like so:

<string>Motorola CE, Copyright 2000+Motorola NC-V3m Phone</string>

Killed and restarted iSync.. and voila, my phone was added.

Now I can sync iCal and my Address book.

Note.. it’s not perfect, after sleeping the MBP, the phone isn’t seen on bluetooth sometimes.. I just open the bluetooth “browse device” bit to kick in a connection between the MBP and phone, and then iSync works.
The sync also fails sometimes when deleting calendar events.. so I just blow the whole calendar away (which is pretty simple… there’s a quick “deleted all events” choice under options) and sync. That might not work for people that really want 2 way syncing to work, I just need my phone to have a copy of what my computer has (from exchange at work).

Some info:
The path to the MetaClasses.plist file in question is:
$ pwd
/Applications/iSync.app/Contents/PlugIns/ApplePhoneConduit.syncdevice/Contents/PlugIns/PhoneModelsSync.phoneplugin
/Contents/Resources
Remember that one… 🙂

I’ve put a copy of the section I added to the MetaClasses.plist file here: MetaClasses.plist

Update: Oops.. I forgot to add, for some reason the calendar bits sync ok, except for the location of the meeting.. trying to figure that one out still.

Update (Nov 15, 12:45): People have asked for my full MetaClasses.plist file so here it is.

SAFE my ass… October 29, 2006 at 5:12 pm

[ Listening: Linger from the album “20th Century Masters – The Millennium Collection: The Best of the Cranberries” by The Cranberries ]

Returning home this past Wednesday night (Oct 25th) I almost had an accident. I took the ramp from the 52 east to the I-15 south, and there was a lot of traffic ahead, so I got onto the Balboa Ave ramp to avoid it by taking Ruffin Rd. down to Aero Dr. Just after getting into the Balboa ramp, some idiot in a pickup truck cut over without warning, and I had to slam on my brakes (thankfully I have anti-lock breaks). Said idiot then proceeds to pass 10 or so cars, then dangerously cuts back into the lane of traffic again. So aside from 2 dangerous lane changes, we have illegal passing on the right (on top of that, I believe it’s also illegal to use an exit lane to pass someone).

The real kicker… it was one of these trucks:

Fsp Truck-1
Click here for info on the program.. sorry pic is so small, but that’s all I saw on the site.

Notice the nice large printing of SAFE standing for some program on the blue depiction of San Diego county.

Clearly they don’t screen drivers worth a damn for that program.

HomeNet September 13, 2006 at 9:58 am

Decided to play with my new copy of OmniGiraffe last night… so I diagrammed my home network.


Yes, I’m a geek with a few too many toys…

Read in a sig file in horde/imp August 19, 2006 at 12:27 pm

[ Listening: Gina Escapes from the album “Battlestar Galactica: Season 2” by Bear McCreary ]

I’ve had a cron job that randomly updates my .signature file on my unix systems every 5 minutes for years now and I really wanted to have the same kind of random signatures in IMP as well. So I made a very simple change to the imp.php file (in <horde>/imp/lib/Identity) that allows you to read in a file rather then only read the signature that you’ve saved in the database. Syntax is very easy.. set your signature in the horde prefrences to FILE:<filename> like FILE:/home/mmarion/.signature and this small bit I added will read in that file instead of printing out the value set in the database.

Patch is simple, download here and here’s how it looks:

--- imp.php.orig        2006-08-19 11:53:24.000000000 -0700
+++ imp.php     2006-08-19 11:53:50.000000000 -0700
@@ -455,6 +455,15 @@

$this->_signatures[$ident] = $val;

+       if (preg_match('/FILE:/',$val)) {
+                       $sigFileSplit=preg_split('/:/',$val);
+                       $sigFile=$sigFileSplit[1];
+                       $sigFileSize=filesize($sigFile);
+                       $sigFilePtr = @fopen($sigFile, 'r');
+                       $val = "-- \n" . fread($sigFilePtr, $sigFileSize);
+                       fclose($sigFilePtr);
+       }
+
return $val;
}

Obviously I didn’t add any kind of error checking for FILE: without a valid file, or for empty files, or files that can’t be read.. but eh.. works for me.

Um.. ouch. August 6, 2006 at 1:55 pm

For those that don’t know me.. I did some serious work on the house in July. I had a complete central air (heat and A/C) installed (which included pulling out the crappy old wall heaters, new furnace/blower, AC, ducting, the works). Then, 2 weeks later, I had my cheesy old thin, aluminum windows replaced with nice new dual-pane, e-whatever coating to cut down on heat, etc. Even had the one tiny sliding glass door in the back room redone as a window (it was too small and rarely was used anyway.. figure this is better for keeping the house heated/cooled).

I just got my first SDG&E bill the other day and for the period of 6/27-7/27 the bill came to a whopping $327!! Ouch. Now, I know that this is a good bit higher then the AC will cost me under normal usage. I saw this because I was home a full 2 weeks during July while work was being done, so that was TV/Stereo/etc on all day. There were almost 2 weeks of using the AC with the old windows that weren’t very good. There were the 2 days of the windows being replaced where, while I turned off the AC as they worked, the house warmed way up into the 90s and the AC had to work hard to cool the house back down. Not to mention those couple of VERY hot days (100+ at least once) and the several times the family was over where the sliding glass door was opened and closed tons of times as people went in and out.

So here’s hoping that from here on out, the bills won’t be too high in the Summer.. maybe $250 max. Even that’s a lot, but I’ve actually had bills hit $200 before, hell my average bill is around $160-170 due to my server that’s online 24/7, 2 tivos, etc. I did bump up my settings a degree during the day and a couple at night too. The Trane system I got has a nice thermostat that you can program each day with a time when you wake up, leave for work, return home, and go to sleep.. so the system will let the temp go up (or down for heating) when you’re gone to save some money.

For those that are curious.. I went with Air + Mechanical for the central air, and The Window Factory for the windows and am very happy with the jobs both outfits did. I would definitely recommend them to anyone looking to get either job done (and already have at work).

Damn.. that’s a lot of data. at 1:44 pm

For those that don’t know.. I finally broke down and bought an Xbox360 a couple weeks ago. For an MS product, they did a lot of things right. The ability to turn the unit on and off via the wireless controllers alone is rather cool. The tie-in to xbox live is very nice too: Buy some smaller games on the cheap (Uno is loads of fun.. yes Uno, the classic card game), you can buy add-ons/themes/etc, and the achievement system for 360 games is neat.

They also use the same live marketplace system to allow downloads of movies and demos of upcoming games which is nice. I already pre-ordered a copy of Dead Rising
but saw that they’d put up a demo for it so figured I’d snag it, along with the demo for Saints Row (a GTA clone coming out).

Then I noticed the size of the demos and took a crappy pic:

Damn those are huge.. we’re talking just under 1Gig per demo average. I knew when buying the unit that the 20gig disk wasn’t really big enough to last. Of course that’s 20 HDD manufacturer gigs too, which really means about 18-1/2 Gig. Remeber boys and girls.. the manufacturers like to say that 20 billion bytes is a gig, but computers do math in base 2 vs base 10 so take your drive size and divide by (2^30) for gigs to get the real size.. not to mention there’s a little overhead from the filesystem.

Anyway, we’ll see how the demos are, but man I hope there’s a way to put in a larger laptop harddrive sometime soon.

And people wonder why I detest Microsoft.. June 9, 2006 at 1:33 pm

[ Listening: Prologue from the album “Battlestar Galactica: Season 1” by Bear McCreary ]

So I’ve been using my new 17″ MacBookPro (that’s the Intel based ones for those not in the know) and right at a month now, and I love it. I know it’s been exatly 1 month because I installed Parallels on it and have been using it to play around with WinXP inside a virtual box. In fact, I played a full game of Alpha Centauri on it a couple weeks ago.

Anyway, it’s been 30 days, so WinXP insists on being “activated.” I’ve tried to, but the activation wizard has informed me that I’ve hit the limit of times this copy of windows can be activated. WTF?!? This is a valid copy of windows XP Pro that I bought a few months after XP was released. I use this install on my gaming box… each time I upgrade, I install this copy and activate it, and retire the previous one.. perfectly within my rights according to the software license. Now that my game box is running x64, I want to use this copy (legally) in parallels.. and I can’t because MS would rather treat even their law-abiding customers like criminals.

My only option now is to buy another license (no way in hell) or go through their phone activation. I would love to, however, note the output of the wizard:

2006.06.09-13.24.16

Notice that due to what looks like a statndard IE “can’t load image” error graphic, you can’t read one of the numbers that I have to read off into the computer.. Thanks MS! Buncha jackasses.

I guess my only option is to call in and try each possible number in that slot. Joy.

As for the MacBookPro… I love it. Apple actually makes products that are nice to use. I’ll have to blog on it seperately.

Update: Called the stupid activation system, I guessed the number was 4.. nope, it was 7 (2nd guess). Then after going through the process of entering all those numbers, it told me “sorry, can’t activate” again. Was put through to a live person (clearly in an India call center) and had to go through it again, but when I explained the situation I was given a valid code to activate. Here’s hoping I don’t have to do this every time I install this copy again… though I bet I will have to.

What’s the deal with the Bandwidth theft pic? April 2, 2006 at 3:29 pm

For those that found their way here due to seeing the bandwidth theft pic…

I’ve put into place rules which will stop people form hotlinking into images on my site. Well, it’ll let them do it, but they’ll have the following image displayed instead:

The reason I’ve done this is because I’ve got several sites linking my images and leeching my bandwidth.. and want them to stop. If you wonder what I’m talking about, Here’s a pretty good explanation of what it means and why it’s basically rude to do so.

If I have an image you want to link to, just copy it and serve it off your site yourself. If it’s from my actual photo albums.. I ask that you ask first, but odds are I won’t care.

If you read a site that you’re seeing the pic on.. mail the owner and ask them to place a copy of the real pic in their own site to serve up from there.