Sunday, October 28, 2007
Ruby on Rails and Leopard: A n00b's view
So Carl and I attended the Leopard release event at the Oxmoor Apple Store. I came home (t-shirt in hand), dropped the disc in my shiny aluminum iMac and performed a standard upgrade. I'm happy to report that there weren't really any problems with the upgrade itself. Here are a few things I found:
- Quicksilver needs to be updated (as of now, their site is still down) to hide the dock icon
- You cannot display a different space on each of your displays in a multi-display setup
- Time machine does not completely eat a drive. It's backup can coexist with other data.
- Disk utility permissions operations seem to run "slower"
I've been bound and determined to learn Ruby on Rails. While on Tiger, I followed Robby Russell's excellent Ruby on Rails on Mac tutorial and rolled my own development stack (using MySQL instead of PosgreSQL). John told me that he hadn't upgraded yet because many of his friends had run in to problems with their own Mac Ports installation of Ruby on Rails after upgrading. This is due to the fact that Leopard includes a really solid Ruby on Rails stack. For those who have a MacPorts installation of RoR and want to keep using it after upgrading to Leopard, Robby has posted instructions.
Since I am a RoR newbie and a bit OCD about where things live on a system, I decided to abandon my MacPorts installation and switch to using the native Leopard Ruby on Rails stack. Rather than being good and learning how to manually remove my installation, I decided to reinstall Leopard from scratch. Yes, this is probably akin to using a sledgehammer to hit a framing nail, but it makes the most sense in my mind :)
So now I have a fresh and happy installation of Leopard. It's time to see what shape Apple's RoR stack is in by firing up Terminal.app.
Doing ruby --version returns ruby 1.8.6 (2007-06-07 patchlevel 36) [universal-darwin9.0] Yay! Ruby is up to date.
What about Rails? Doing rails -v returns Rails 1.2.3 Hmm, Rails is slightly outdated so I should probably update it. Thankfully, this will be an easy task since gem is also installed. I'm thinking if Rails is outdated, other gem packages are likely outdated as well. Let's updated everything (since I know nothing will break since I'm still learning).
I run sudo gem update --include-dependencies. So far, so good. Several packages are updated before it asks me this:
Attempting remote update of fastthread
Select which gem to install for your platform (universal-darwin9.0)
1. fastthread 1.0.1 (ruby)
2. fastthread 1.0 (ruby)
3. fastthread 1.0 (mswin32)
4. fastthread 0.6.4.1 (ruby)
5. fastthread 0.6.4.1 (mswin32)
6. Skip this gem
7. Cancel installation
I select 1, expecting things to continue on their merry way.
Building native extensions. This could take a while...
ERROR: While executing gem ... (Gem::Installer::ExtensionBuildError)
ERROR: Failed to build gem native extension.
ruby extconf.rb update
can't find header files for ruby.
WTF???? Oh right. I've run in to a similar situation while trying to install the stack on Debian's Etch. The problem was that I didn't have make tools installed (John confirmed this for me). So how does one get those on their Mac? Easy! Drop the Leopard install CD back in your computer and select "Optional Installs", then "XCode Tools". You'll want to run XcodeTools.mpkg. Selecting the standard installation options will cover what you need to successfully get your gems updated. You won't even have to restart!
Now running gem update --include-dependencies results in Gems: [blah blah blah blah blah] updated.
Let's see if our Ruby on Rails installation works by running a demo server. I navigate to one of my project folders and run script/server start. The console reports:
=> Booting Mongrel (use 'script/server webrick' to force WEBrick)
=> Rails application starting on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
** Starting Mongrel listening at :3000
** Starting Rails with development environment...
** Rails loaded.
** Loading any Rails specific GemPlugins
** Signals ready. TERM => stop. USR2 => restart. INT => stop (no restart).
** Rails signals registered. HUP => reload (without restart). It might not work well.
** Mongrel available at 0.0.0.0:3000
** Use CTRL-C to stop.
Hooray! Navigating Firefox to http://localhost:3000/ results in the "Welcome Aboard" rails demo page! Hooray! I now have a working and up to date Ruby on Rails installation! Next time, I'll go through installing MySQL so real web development work can begin.
Continue reading "Ruby on Rails and Leopard: A n00b's view".
Posted by
Kolonay
at
11:37 AM
10
comments
Links to this post
Labels: Leopard, Mac, OS X, Ruby on Rails
Friday, October 26, 2007
Mall cop protecting the Apple Store
Posted by
Kolonay
at
6:06 PM
1 comments
Links to this post
Labels: Apple, Leopard, Louisville, OS X, Release
Wednesday, October 10, 2007
JPG Magazine Entry: Emotion
Posted by
Kolonay
at
11:58 PM
0
comments
Links to this post
Labels: Digital Photography, JPG Magazine, Strobist
To Do: Things I would like to do before 2008
In no particular order
-Sell off the parts of my studio that I no longer wish to keep.
-Build my first Ruby on Rails app.
-Attend another Strobist Meetup.
-Buy a film rangefinder.
-Lose 20-30 more pounds.
-Take more photos.
-Print a photo book.
-Print business cards.
-Redesign my blog.
-Find a new camera bag and reconsider my lighting bag.
-Add a Vivitar 285HV to my lighting kit.
Continue reading "To Do: Things I would like to do before 2008".
Posted by
Kolonay
at
6:22 PM
0
comments
Links to this post
Tuesday, October 9, 2007
Follow Up: First Annual Strobist Meetup Asheville, NC
As it turns out, putting one of these things together isn't really that hard when you have a lot of great people to help put things together and you pay attention to details.
I think we might have to have one of these much sooner than a year from now :)
Pictures can be seen here.
Read the follow up thread here.
Special thanks to the participants which included:
Me
Clark
Eric
John
Jeremy
Jason
Tim
Dave
Brian
Anthony
And of course, a special thank you to David Hobby, without whom, none of this would be possible.
Continue reading "Follow Up: First Annual Strobist Meetup Asheville, NC".
Posted by
Kolonay
at
5:17 PM
1 comments
Links to this post
Labels: Asheville, Digital Photography, Strobist
Tuesday, October 2, 2007
Mission: Statement
So this blog hasn't really been used for much of anything useful lately (if ever). Seems these days, I'm into my photography and my work. Until I move, my outward social life is sort of at a halt due to the fact that I commute 2.5 hours daily round trip. I suppose it would be nice for me to say that this blog is used for something, so that it has a purpose and isn't stuck in the box of old memorabilia (with Castle Greyskull and Optimus Prime).
With that in mind, I will primarily be talking about my quests to bring Ruby on Rails and agile principles to work. I'll also talk about my adventures in photography.
Pointless, isn't it? Keep in mind that I'm writing this to feel like my blog is active.
Continue reading "Mission: Statement".
Posted by
Kolonay
at
2:09 PM
0
comments
Links to this post













