Saturday, November 21, 2009

WOD 11/19

Oops, almost forgot to post the WOD from my very first crossfit class!

Warm-up:
650m Run (around the block)
Progression of Double-unders and knees-to-elbows: 10 9 8 7 6 5 4 3 2 1

3x Squats (face the wall and hold for 20 seconds, 7 seconds rest)
5x3 Weighted push-ups (70#)

15 minutes of Thrusters (20#) vs. 500m row

At the very end, my calves were cramping up. This is the first workout that ever got my legs to cramp up during the workout!

Tuesday, November 17, 2009

Workout of the Day, 11/17/2009

650m run

21 reps: 175# bench, pull-ups (4:27)
15 reps: 160# bench, pull-ups (3:43)
9 reps: 145# bench, pull-ups (2:02)

3 sets of 7 burpees
100 crunches

(had to lighten the bench press weight since I couldn't get the bar moving at all)

Sunday, November 15, 2009

Workout of the Day

Seeing as I just joined Crossfit, I'll definitely need to post my WOD!

This workout is my modification of the base workout, since there are no good places to do pull-ups along the Embarcadero.

Run 650m (Red's Java House -> "dog park" at South Beach)
40 lunges
30 push-ups
20 sit-ups
10 burpees


Tuesday, August 11, 2009

Quick Chrome Tip

A lot of people ask me questions about sites that don't work with Chrome. I've given the tip to several people, so I thought I would post it here.

There are a number of sites that use a technique called user-agent sniffing. Browsers send an identifier when they connect to websites that indicate what kind of browser they are. Some sites serve different content based on the user-agent.

Anyways, many sites don't detect Chrome correctly, which makes the sites not work in Chrome. There's a quick (but temporary) work-around for those of you on Windows:
  1. Create a new shortcut to chrome.exe (you can copy an existing shortcut)
  2. Edit the shortcut (right click it and click "properties") and add a switch to change the user agent: in the "Target:" field, add this to the end:
"[...long path here...]\chrome.exe" --user-agent="Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.0.12) Gecko/2009070611 Firefox/3.5.12"
Then click "ok". Then, if you have Chrome still open, close it.

Now, if you launch Chrome via that new shortcut, it will 'pretend to be' Firefox 3.5. Sites that block Chrome but allow Firefox should work now.

Enjoy,
Glenn

Saturday, August 8, 2009

My first magazine cover!

I'm on the cover of the latest edition of Linux Journal magazine, along with like 30 of my closest Google Chrome co-workers.

Go out and buy multiple copies of the magazine today:

Saturday, July 11, 2009

Create directory in python snippet

I've been writing more python these days, and I ran into a need for a method that would recursively create directories if they don't yet exist. I'm sure many other people have written this same thing better, but I thought I'd post it in case anyone out there found it useful:

import os

def CreateDirectory(dir):
"""
Method that creates the directory structure given.
This will create directories recursively until the given dir exists.
"""
if dir[-1] == os.sep:
dir = dir[0:-1]
if not os.path.isdir(dir):
if not os.path.isdir(dir[0:dir.rfind(os.sep)]):
CreateDirectory(dir[0:dir.rfind(os.sep)])
os.mkdir(dir)

Advertising FAIL of the day...


Really? WTF.

I'm not sure what's stranger -- the fact that this site actually exists, or the fact they paid for this advertising.