Articles

ignoring files

We don’t need Git to version everything in our projects, be it compiled source, files with passwords, or temporary files that editors love to create. Usually keeping stuff out of your VCS’ hands is a task that is hard to manage and annoying to set up. Not with Git! Using the .gitignore file along with some other options, we’re going to learn how to set up per-project and per-user ignores.

Is [my show] on yet?

Not long after I first deployed isLOSTonyet, seaofclouds sent me a github message about his own LOST countdown site. I explained my grand vision for my site, and suggested we join forces. Luckily, he too liked the idea of tracking fellow LOST geeks on Twitter, and was able come up with a beautiful design for the new site.

is lost on yet? screenshot

Runaway ruby process uses 100% cpu

I’ve noticed over the last year or so that occasionally Ruby would start using 100% and I would have to kill -9 it.

I figured that I was the only one with this problem, and for some reason assumed that it was cucumber, since it usually happened after running features.

However, it looks like it happens when I close an iterm window with an open ruby console without quitting the console first.

the staging area

One of the most essential concepts to Git is that of the staging area. Its use can fundamentally change how you work, for the better! Let’s go over how exactly it works and what you’ll need to know to use it.

With most other version control systems, there’s 2 places to store data: your working copy (the folders/files that you’re currently using) and the datastore (where the version control decides how to pack and store your changes). In Git there’s a third option: the staging area (or index). It’s basically a loading dock where you get to determine what changes get shipped away.

restoring lost commits

So, you just did a git reset --hard HEAD^ and threw out your last commit. Well, it turns out you really did need those changes. You’ll never be able to implement that algorithm that perfectly twice, so you need it back. Don’t fear, git should still have your commit. When you do a reset, the commit you threw out goes to a “dangling” state. It’s still in git’s datastore, waiting for the next garbage collection to clean it up. So unless you’ve ran a git gc since you tossed it, you should be in the clear to restore it.

Open sourcing our twime tracker

Oh my god, I just came up with a new phrase. Twime tracker. Shoot me now, please.

Anyway, about a year ago we started writing a “twitter meets time tracking” application, XTT, over at ENTP to track our time. It was more than that, really.. more like 37signals’ In/Out (which they hadn’t released yet), but also like a closed-group twitter-style status update, the difference being we track the times for each status.

Using decision trees to predict paying users in Ruby

Over at Ilya Grigorik’s blog, there’s a great post on using decision trees to figure out what attributes matter in a decision

I had some hiccups trying to implement this in a project, so this is a quick post on how you might actually use his decisiontree gem in your app.

Moonshine: Configuration Management and Deployment

On Wednesday, at the January 14th 2009 meeting of the Atlanta Ruby Users Group, Jesse Newland presented a talk on our latest project: Moonshine. Moonshine is an opensource configuration management and deployment system being released later this month.

Windows 7 - The Bleeding Edge

Well I finally bit the bullet. While I had tried vista on my work laptop, and after sweeting it for 3 months, went back to xp.
Microsoft Windows 7 seemed to be the answer to what I was looking for.

So I finally decided to use the Beta on my main gaming machine. My main work machine is a MAC.

First, Lets see how well the beta behaves. So I created a new VM on my Mac, and did the install from the ISO.
Wow, it went smooth and easy. Very fast install compared to XP. And so much better than Vista.

cleaning up untracked files

Our first reader submitted tip comes from Dav Glass, and it elaborates on a command used to keep your repository nice and tidy. Have a tip you’d like to share? Submit it!

Files and directories may pile up in your working directory that are left over from merges, generated, or perhaps got mistakenly put there. Whatever the case, you don’t need to ignore them in your .gitignore, you just need to remove them. Running

git clean -n -d

Articles | Rails Fire

Articles

Making Git Commands A Little Shorter

Most of you git geeks probably already knew this, but recently I learned how to make git a little more usable for me.

One of the things I appreciate about Subversion’s command line interface is that, usually, you don’t have to type the entire command name. As long as you enter enough of the command so it can’t be confused with another subversion command, it will work.

For example, instead of doing:

svn status

I always do

Yahoo-Flavored Hadoop on GitHub

Yahoo’s openness continues today with their announcement of their Hadoop distribution being hosted right here on GitHub: http://github.com/yahoo/hadoop.

Read all about it on Yahoo’s Developer Blog.

"And your Mom, too." Ruby-talk best practices.

Mailing lists (and bulletin boards and forums and so on) are important parts of becoming a better developers. Even the best programmers need help, and a mailing list such as ruby-talk (or the Usenet version, comp.lang.ruby) is the traditional place to go.

Mailing lists are also a good place to get better at your craft; watch the list, and try to answer questions. Think of it as pop quizzes at Ruby U.

GitHub:FI Pricing now Public


This past week since our initial offering of our Firewall Install product has been an exciting one. We received over 300 quote requests on launch day, with more filling our inbox since. We really weren’t prepared for the level of response we received and fell way behind trying to provide quotes for everyone.

User Groups - Added Chicago Ruby

This is a list of Rails User Groups from around the world. If you are part of a User Group not on this list, please feel free to add it. If you can’t find a user group in your area, look on Rubyholic, RubyGarden User Group’s Page, or the WWR Groups. There may be a Ruby user group out there that has a lot of Rails interest, too.

Finding Visitor Locations in Rails

I’ve got an application that I work on where the client wants to track which countries they’re seeing click-throughs from. They want this in real time and in the application’s UI, not in an external package such as Google Analytics. There are various ways to guess at country, but for the purposes of this application, basing it on the IP address and where its range is assigned proves to be good enough.

Discussing code reading and testing with Dave Thomas, Cory Foy and Tim Bray

Pat Eyler just published an interview/discussion with Dave Thomas, Cory Foy, Tim Bray and I on the subject of code reading and testing legacy code. I think the resulting article is a very interesting read with a lot of insight (thanks to the other participants). It was a fun discussion which left me feeling honored to be among such distinguished people.

BigDecimal Vulnerability in Ruby 1.8.6 and 1.8.7

Yesterday, the first security vulnerability since Engine Yard took over maintenance of Ruby 1.8.6 was reported. It is a Denial of Service vulnerability in BigDecimal, by which an attacker can cause a segmentation fault by providing a very large number as input. ActiveRecord relies on BigDecimal, but this is not Rails specific.
Today, as part of our [...]

Subdomains, SubdomainFu, and Cucumber

In order to use Cucumber to test a site that uses subdomains to scope things like user accounts, add something like this to your relevant step:

Given /^An account$/ do
  account = Factory(:account)
  host! "#{account.subdomain}.example.com"
end

and if you’re using SubdomainFu, make sure the tld_size for your test environment is set to 1 (or whatever is appropriate). By default it is set to 0. You can do this in features/support/env.rb:

Reading and Testing Your Legacy Code

In this week's installment of Questions Five Ways, we're talking about testing and code reading as tools for dealing with legacy code. This week's participants are Cory Foy (@cory_foy), Dave Thomas (@PragDave), Antonio Cangiano (@acangiano), and Tim Bray (@timbray).What is the relationship between testing and code reading when dealing with legacy code, and how can we use the two processes to

Promotion Agency | Rails Fire

Promotion Agency

Ruby Gets An Official Spec: Heading To Become An ISO International Standard

red-specs.pngIt's long been a bone of contention in the Ruby world that Ruby, as a programming language, doesn't have an official spec (though RubySpec has been a noble, community effort to build an executable specification for Ruby).

Syndicate content