I’ve just started to work on a series of screencasts. The topics will be varied, but will center around Ruby, Rails, JavaScript, CoffeeScript, iOS, and the like, ranging in time from 2 minutes to 10-15 minutes. Because I’m just starting to get my feet wet in this area I thought I would share the first of these screencasts with everyone here in the hopes of getting some feedback, good or bad.

Read more →

Travis CI and Heroku are two of my favorite tools. Recently I tried to figure out if there was an easy way to have Travis automatically deploy to Heroku once the tests have passed. Turns out it’s incredibly easy! All you need to do is add the following as your after_script in your .travis.yml file. after_script: # Install the Heroku gem (or the Heroku toolbelt) - gem install heroku # Add your Heroku git repo: - git remote add heroku git@heroku.

Read more →

My editor/IDE is better than yours! That’s right. My editor can do everything, and yours is just a toy. My editor let’s me write code, edit code, delete code. It can generate Lorem Ipsum, flay a salmon, and program my VCR. Can your editor do that? I doubt it. My awesome editor makes me a better developer. More importantly it makes me a better developer than you. If you don’t switch to my editor you’re a fool and your code must clearly be terrible.

Read more →

Conferences, user groups, etc… are about two things as far as I’m concerned; education and networking. Those points often coincide with one another and are not mutually exclusive. Recently at conferences, user groups, meet ups, what have you, I have noticed a distrubing trend; developers sitting in the back of the rooms, hallways, and other common areas, hacking away on their laptops. Lot’s of time, energy, and money is spent to create an environment at these events where people can come and learn both from the speakers of the event as well as from each during the social events that are scheduled.

Read more →

Beware Your Users: Every developer should already know about, and work to prevent, scripting attacks on their site. Scripting attacks are one of the easiest ways for a hacker to attack your site, they are also one of the easiest attacks to prevent. Whenever you let an end user enter text into a form on your site, and then display that text to other users on your site, you’ve opened yourself up to this sort of attack.

Read more →

Lately I’ve been doing a lot of work with PhoneGap, now known as Cordova. PhoneGap lets you write «native» iOS, Android, Blackberry, etc… applications using standard web technologies, such as HTML, CSS, and JavaScript. They also give you a JavaScript API to access parts of the device, such as the camera, the accelerometer, the compass, etc… In this article I would like to take a quick look at how to take a new picture, or use an existing library photo, and how to upload it to a webserver somewhere.

Read more →

Recently I fell upon a way of working that I think is just fantastic. So far I have no complaints about it, and neither do my clients. How I used to work In the past I would write my Rails applications just like everyone else did. I had all my business logic in my models and my controllers were very lightweight. Just enough to have the data I need to render the page.

Read more →

As you may or may not have noticed there’s a new blog in town! That’s right, I’ve ditched the zero, WordPress, and got with the hero, Jekyll. And I have to say, it sure feels good. WordPress worked well for me for years, but I have to say that I never enjoyed the process of writing a technical blog in a browser. I hated the lack of tools that my editor has at it’s disposal.

Read more →

Before I start this article, let me apologize for the lack of writing over the last six months. My only excuse is that I’ve been working on a new book and that is where all my writing energy has gone. So with apologies out of the way, let’s talk pagination. Dealing with pagination in any application is never easy. There are a lot of great libraries out there that help you better handle this awkward, but unavoidable part of application programming.

Read more →

I’ve started working this week on an example application for the next book I’m about to write and I wanted a simple way for my readers to easily run the app (it’s going to be a single HTML file with a ton of cool JavaScript going on in it). My first choice for running this app was to use the popular Ruby library, Rack. If you are unfamiliar with Rack, please check it out.

Read more →