Moved to Fairfax!
&& [ Cool, Cycling ] && 1 comments
I’ve finally found my bum-ass a place to live! Fairfax, CA in beautiful Marin County. Im going to give you all some good reasons to visit:
-
Fog, what fog?
-
My street turns to dirt in 1/4 of a mile from my house with several trailheads.
-
We have a hottub.
-
Good mountain biking trails.
-
Good people
-
Close to S.F
Great place, hardly as many yuppies as the rest of Marin co. I’m pretty exciting to finally have a place to rest my head, get some momentum, and become established. See ya out there!
Some lessons leared.
&& [ ] && 1 comments
1988 was a good year and last weekend brought 23 years since then of me walking this planet. As my friend Matt told me, growing old is a privilege and I’m happy to have made it this far.
Age 22 was probably one of my best. It brought my last year of college in which getting all my classes out of the way early finally paid off - I got to mostly float through and have some fun. Socially it was a rollercoaster, both being gone every weekend for bike races and meeting new people in town.
How could I not miss the Haus? Living at the Bike Haus had its ups and downs, but mostly it was rad. I got to meet and hang out with so many people (hippies) just because I lived there, it almost seemed like
cheating. The place truly was a community center for better or worse. Smelled like one too. I learned some important things here: how to clean insanely dirty dishes, to ignore the smell of body odour and to not let your roomates practice drums at 11:00 at night when you have anal retentive neighbours! Seriously though - clear communication. When your roomates do something that you perceive as wrong or annoying its better just tome come forward about it. Even if it is one against the herd and may cause an awkward living situation for a while. Especially important in precarious situations such as living in the Bike Haus. I haven’t heard anything about the place since I left, but I hope its getting used. R.I.P.
Racing mountain bikes was the best thing I could have done with my weekends in college and my only regret was not getting into it sooner or going harder. It was amazing for so many reasons. First of all, I never really had a competitive outlet in college - unless you consider pissing matches between comp sci nerds competition (which it is, but in a really obnoxious, annoying I-dont-even-want-to-participate kind of way) so it was great to get out there, lay the smack down and feel good about coming out on top - some of the time. I only got 2 podiums the whole season but it was all worth it. There is much to be learned in humility and defeat as well. It was also extremely physically demanding. While most people I knew were out every weekend getting drunk and feeling like shit - my racing friends and I were doing 9am bedtimes in order to wake up at 6:00am on race day. Everything changed - diet, sleeping habits, physical physique and attitude. I think I may have even considered myself an athlete and damn if I didn’t feel really good too - probably in the second best shape of my life just behind my tour in New Zealand. It was almost impossible not to feel slightly elitist when returning to school after a weekend of racing knowing that you just put yourself through more pain and suffering than most people in class sitting around you would in a year - and you liked it too. But everyone needs a bit of an ego and confidence boost every once and a while so I don’t feel bad. It definitely worked in my favour at the party and social scene too. But MOST importantly I learned that, and this applies to life in general, if you want one of these:
You have to go through a bit of this:
[caption id=”attachment_520” align=”aligncenter” width=”330” caption=”Trevor Pratt, destroyer of wheels.”]
[/caption]
And that just all there is to it.
As far as careers or whatever goes I guess that’s going pretty well too. All those years of being a computer nerd in High School finally paid off, because now I’m that same nerd but getting paid for it. I’m still not sure what to say when people ask me what I do for a living. My answer is usually “computer stuff” but in reality I do a bit of all computer stuff. No Im not making the new Facebook. Mainly programming (which I’ve gotten so much better at in one year) as well as some system admin type work. The jobs are challenging and the pay is good so I can’t complain - but I can’t let that get to my head. I will ALWAYS remember that I do this some of the time:
So that I can do this most of the time:
Because I've seen those commuters honking their horns, crowding on the BART, who have worked all their lives and I can feel the frustration and pain in them. I'll never go there. Money can be a dangerous addiction and I've felt it try and grasp at me already, but when that happens I usually just say f**k it and go for a ride.
Heres to living the dream and looking forward to 23.
Videos that make me go like wow
&& [ ] && 0 comments
I’ve been spending more time you youtube lately, especially on Mondays while I recover from the weekend races. Here are a couple of bike related videos that really had me glued to the screen.
I didn’t even know what a match sprint was before I saw this video but after watching I want to head up to the Alpenrose velodrome and give it a shot. It’s old school, and I don’t think there are that many track stands in modern competition, but it is still very cool to watch:
Headbutting. I’ve got to try this. From last year’s Tour, Mark Renshaw headbutts the competition:
Let Me Go!
&& [ Music ] && 0 comments
I’ve been trapped in the terrible place known as finals week for too long, finally I’ve been let go. This quarter is behind me, for better or for worse. Just wanted to share a song real quick that I thought was really good, Let Me Go by Phantogram.
I’ll really be going - as fast as I can - in 3 days. First XC race of the season up in Echo, Or. I’m going to need to find some faster music by then. Hello spring break!
Copy Contents of one S3 Bucket to Another.
&& [ code ] && 12 comments
Need to automate copying files from one Amazon S3 bucket to another? So did I. Everything I found on google, like this, was useless. Most of the scripts I found required downloading the objects first to the local machine and then reuploading them to the destination bucket. Unacceptable, especially if you are dealing with a large and or many files.
I’ve never written a line of Ruby before, but it seems like there are some great AWS libraries for it, so I decided to give it a shot. There is a cool library out there called right_aws. You can install it using #gem install right_aws. Then simply copy this script:
{{< highlight ruby >}}
!/usr/bin/env ruby
require ‘right_aws’
S3ID = "Your AWS ID Here"
S3KEY = "Your AWS secret key"
SRCBUCKET = "Source Bucket"
DESTBUCKET = "Destination Bucket"
s3 = RightAws::S3Interface.new(S3ID, S3KEY)
objects = s3.list_bucket(SRCBUCKET)
objects.each do |o|
puts("Copying " + o[:key])
s3.copy(SRCBUCKET, o[:key], DESTBUCKET, o[:key])
end
puts("Done.")
{{< / highlight >}} Make sure the file is executable and you should be able to run it via command line on any unix system. To make a generic ruby script get rid of the first line.
I know its pretty brutish, probably sucks in more ways than one, but for now it works. And I think I like Ruby :D
Fink Ployd
&& [ Music ] && 0 comments
Wow, what a great week on hypem.com. I haven’t been checking in there a lot lately but I did a few days ago and some of the new stuff really blew my mind. Sure, there were the usual hip hop/electronic mashups and Passion Pit wannabe bands, but every once and a while you pick up on a gem.
Like this one from Pretty Lights. I love Pink Floyd, and I like remixes, which probably explains why I’m so into this song:
Pink Floyd Time Remix - Pretty Lights
You can download a ton of this guy's music off his eye popping website. Seriously, who designed that thing? I want to be their friend.
How to select multiple elements dynamically using jQuery
&& [ Programming ] && 0 comments
I’m a bit of a jQuery noob, but I love it. Recently I came into a situation where I wanted to be able to select a bunch of input elements on a page that shared the same first part of their ID’s. Not only that but it had to be dynamic - that first part of the Id had to be stored as a variable rather than be hardcoded. jQuery’s selectors, like input[] do not allow you to use variables. However, it is possible to use the filter() method to select what you want from something more general.
So lets say I have something like this:
<input type="text" id="qac1_59"> <input type="text" id="qac1_60"> <input type="text" id="qac1_61"> <input type="text" id="qac2_65"> <input type="text" id="qac2_66"> <input type="text" id="qac2_67">
But I only want the first group (qac1), and the 1 is an attribute of the clicked element(can also be from anywhere, passed into the fucntion for example). I can do this:
$(".radio-box").click(
function(event) {
var mainId=$(this).attr("mainId");
var comment = $('input[type="text"]').filter(function(){
return this.id.match("qac" + mainId + ".*");
});
});
This will return all the elements that start with qac1 and you can now perform actions on them, such as comment.val(). The filter() method takes regex expressions so you can do all sorts of interesting stuff with it. Hope this helps. Cheers.
Your Bike Frame And You
&& [ Cycling ] && 1 comments
It seems every ride I go on lately isn’t complete until someone gets into an argument about which material makes the best bike frames. Face it, we’re kinda religious about that stuff. Its almost like defending your major in college or something else equally as meaningless. In any case, I know where my allegiances lie, but I thought I’d make some insulting generalizations at everyone’s expense anyways.
[caption id=”attachment_448” align=”alignright” width=”358” caption=”Its made of a bunch of straws . er… strands.”]
[/caption]
PLASTIC
Its actually considered glass, ok. Besides, I like to call it carbon. If you want to get really technical, it’s actually Carbon fibre-reinforced polymer or CFRP for short. My bike is at the forefront of technology with it’s amazing strength to weight ratio and fancy shaped aerodynamic tubing. All us pros are on it, and for good reason. Its the lightest, stiffest most expensive frame material out there. Oh crap, I accidentally laid my bike down on some moss covered rock during a beat-per-minute break. Whats that? the whole frame is now unrideable? Lame. Good thing I only spent a few grand on it, and this guy can manufacture some more materials to make me another one. (Actually a worker from a carbon plant).
Steel is real, man. I couldn’t imagine riding anything else. Probably because I haven’t for the last 50 years… nevermind. Those carbon guys have it all wrong. Steel is the heaviest, mushiest, cheapest frame material on the planet. It has the best ride quality, because in my head I can imagine that the nearly indistinguishable flex of the frame helps absorb bumps in the road or trail. Also, its kinda ironic to buy an expensive new frame made from the oldest bike frame material ever made - which is exactly why mustache toting, kale munching, rayban loving militant recyclers often choose steel as their frame material of choice.
ALUMINIUM AL-ew-MIN-ee-əm
Hi. My name is Steve. Steve Johnson. I ride aluminum because it is strong, light and relatively inexpensive. Also, they carry it at my local bike store. What can I say about my bike? There are thousands others just like it. I like it. It’s got some cool decals on it. Once I was riding and nobody told me that they liked my bike. Actually, thats every ride. Oh well. My good personality makes up for it.
I’ve always wanted a wood bike. 100% renewable, clean energy, pedaling machine. Its so green. Good thing my multiple investments in Amazon Lumber, Inc have gotten me to the point where I can finally afford one! Plus it looks hot on top of my Audi! My only complaint is that once I rode it to my local coffee shop to get my daily macchiato and when I came back outside, some punk had burned the thing down to the ground.
TITANIUM.
I know whats up.
Seriously who cares! Just ride the damn thing!
Best Bash Prompt Ever
&& [ Linux, Technology ] && 3 comments
Ever wish your command line was a little more friendly? Maybe you’d like to add some emotion to your static computing environment? I give you the smiley face bash prompt!
[caption id=”attachment_441” align=”alignnone” width=”495” caption=”Font is terminus, btw.”]
[/caption]
This bash prompt displays a green smiley face or a red frowny face depending on the return status of the last command executed. To use it, insert the following code to the end of your ~/.bashrc file:
PS1=”[\e[01;32m]\u@\h [\e[01;34m]\W `if [ \$? = 0 ]; then echo -e ‘[\e[01;32m]:)’; else echo -e ‘[\e[01;31m]:(‘; fi` [\e[01;34m]$[\e[00m]“
Happy (or sad) computing!
There is no Job Quite Like This








