Feb
6
Barefoot hiring a Rails developer
February 6, 2010 | Leave a Comment
We’re looking to add to our team again. If you are passionate about Ruby and Rails, come join me and the team:
http://jobs.barefootproximity.com/2010/01/27/senior-rails-developer/
Sep
4
Rails and undefined method ‘manage_gems’
September 4, 2009 | 2 Comments
Going through the update process today on a site built over a year ago. It had an older version of Rails frozen and I was simply trying to update to a newer version of the gem.
Issuing the rake rails:freeze:gems command didn’t work. Got the following:
rake aborted!
undefined method `manage_gems’ for Gem:Module
I knew I had updated RubyGems. That wasn’t it.
gem env
Shows the gem environment variables. Sure enough I was up to date. So what was causing the old method to be called? I looked in the boot.rb file for anything suspicious. There are some differences between an older version of Rails’ boot file and newer versions. Replaced it. No dice. It was still something to do with this app because other apps could freeze the gem.
It hit me. Unfreeze the older version completely and try again.
rake rails:unfreeze
Removing the old version worked. Not sure what was in there. But regardless, I was able to freeze to the new 2.3.4 version with the security patches. Hope this helps someone else before they go down the road of blaming RubyGems or soemthing.
Jul
20
Speaking tonight about git and Github
July 20, 2009 | 2 Comments
I’ll be giving a presentation on Git and Github tonight at the local Web professionals meeting.
Details here: http://www.screamingmonkeys.org/
Join us if you are here. We’ll start off on beginner and work our way to more advanced topics should people want that.
Apr
4
Mickey’s receives more awards
April 4, 2009 | Leave a Comment
I’ve been fortunate enough to work on the Mickey’s beer site for three years now. And each year the pieces we add on are recognized and awarded. This year was no exception. The Mickey’s site received the following at the regional ADDYS and are moving on to nationals:
3 GOLDS
- Mickey’s Puzzle Generator – Mini-Site- INTERACTIVE MEDIA
- Mickey’s Puzzle Generator – Banner Ad – INTERACTIVE MEDIA
- Mickey’s MMA Q&A – Mini Site – INTERACTIVE MEDIA
5 SILVERS
- Mickey’s MMA Q&A – Tito Ortiz – INTERACTIVE MEDIA
- Mickey’s MMA Q&A – BJ Penn – INTERACTIVE MEDIA
- Mickey’s MMA Q&A – Kendall Grove – INTERACTIVE MEDIA
- Mickey’s MMA Q&A – Banner Campaign – INTERACTIVE MEDIA
Mar
20
Import Typepad posts into Rails using Rake
March 20, 2009 | Leave a Comment
A client at Barefoot wanted to preserve their old Typepad blog posts in the new site we were building for them in Rails. I figured this might be a common task that others go through, so I wrote a Rake task and it’s hosted at Github. It uses the TP RSS2 feed and does some massaging of the content. Typepad does some odd things with content, specifically around images embedded in posts. I’m sure not every content situation is handled, so feed free to fork it and make changes.
Mar
5
I was tasked with moving a CakePHP based site from Dreamhost to a Grid Server at MediaTemple, and while doing so thought it would be a good time to get the site into Git and deploy with Capistrano. Turned out to be a little bit of headache. Last night I was finally able to complete a recipe that would deploy the site to the Grid Server (gs). It required a few directory changes and symlinks put in place, but it works now. The process for deploying a Rails site to a (gs) container is pretty well documented, but deploying a non-Rails site to a domain directory on the Grid Servers is not. Hopefully this helps others. I’m not sure how common it is in the PHP world to deploy a site using Capistrano.
Feb
25
Rails delete_all and autoincrement
February 25, 2009 | 5 Comments
More of a note to self, but others may benefit.
Keep in mind when doing a delete_all on your model to empty the table, that you may want to reset the auto_increment value if you are using mySQL. Reason being, if you are completely reloading data into a table, you may have legacy bookmarked links that rely on your id(s).
Let’s say you are loading some job postings from an RSS feed. You may want to delete all records each time you reload the data just to make sure you are getting any edits to any records. But, your auto_increment will increase with each reload which will break links people may have referenced prior to your reload. In order to reset the auto_increment, simply issue the raw SQL command like so:
Career.delete_all
Career.connection.execute(’ALTER TABLE careers AUTO_INCREMENT = 0′)
I’ll have to look into the delete_all method in ActiveRecord and see if I can apply a patch that accepts a conditional to auto reset the auto_increment value.
Jan
14
keeping track of daily goals and time
January 14, 2009 | 8 Comments
I’m a wannabe GTD geek (http://www.43folders.com/2004/09/08/getting-started-with-getting-things-done), trying to make todo lists and stay organized, etc… I have inbox zero down at this point. BUT, there were always two aspects of GTD that I have been looking for a good solution for.
The first is keeping track of my time throughout the day. I’ve settled into a quick format text file where I list what I have worked on once I complete the task. For example, “8:15 – 9:45 processed inbox”, or “10:45 – 11:30 diagnosed and fixed locations error in Project X.” I was doing this in Evernote, but it always seemed a little overkill to have Evernote running all day just for a simple text file. Plus, I don’t like the Evernote icon. Stupid complaint, I know.
The second thing I was missing was a good, simple way of storing my daily goals. AKA, my TO DOs. Again, this seems like a simple text file would suffice. I use Basecamp for most to-dos so they can be collaborative, but I want a quick hit list for my own eyes. It doesn’t need to be a good looking Dashboard widget, or a nifty menu bar only app. Just a quick text file would work. Something that can be invoked and managed with the keyboard. However, I don’t want it to just get lost in my files. That is why GeekTool caught my eye today (http://projects.tynsoe.org/en/geektool/) is an OS X utility that can display text files and shell commands on your desktop. It can be done in a really unobtrusive way too. With a little TLC, you can have the text from GeekTool blend in very well with your desktop, which is easy for me because I use a solid color – black. So, I started thinking, using GeekTool to display my time and daily goals files will be perfect. But I need to be able to edit them quickly. I remembered Quicksilver had an append/prepend functionality added as an advanced feature. Instructions on the wonderfully awesome 43 Folders (http://www.43folders.com/2004/09/04/quicksilver-append-to-a-text-file-from-anywhere). So, I think this will work really well. I’ve setup a time.txt and a todo.txt and stored them in my project files directory that is already in my QS catalog.
So, using Quicksilver I can now append time entries to my time.txt file. It’s always accessible by simply going to the desktop. I can quickly add todo items to my todo.txt as well. I’m going to try this for a while, I think the power of Quicksilver append is going to win me over. If anyone has better suggestions for keeping track of time or todos, I am happy to hear them.
UPDATE: small change in process. GeekTools apparently has a problem updating more than one text file. So to get around this, I changed my entries to be Shell commands versus Files so I could set a refresh rate. I simply used a command like: cat ~/time.txt to show the text file in a similar fashion to use the File entry type. I set the refresh rate at 5 and that seems to work without bogging down the system.
Dec
17
Riding Rails: Introducing Rails Metal
December 17, 2008 | 5 Comments
Rails Edge introduces Rails Metal, based on Rack. Think of it as a way to bypass the Rails framework on certain requests. DHH gives the example of the Campfire chat application. I’m thinking about Flash Remoting (AMF). No reason to really call a controller, walk through the Rails stack, just to have separate logic query the database and return a serialized object. This could make Remoting through Ruby really really fast.
Riding Rails: Introducing Rails Metal.
Dec
17
Changing Git History
December 17, 2008 | Leave a Comment
Scott Chacon has posted an entry using the new Github pages on how to edit commit messages in Git. Really handy and not necessarily the most intuitive thing. Great to have instruction. schacon FTW!
By the way, the new Jeckyll based Github pages are sweet for developers working on open source projects.