Category Archives: Habits

Test First as a Habit

I am not a TDD zealot (or even really a practitioner), but on The App Guy podcast, Paul Kemp asked me if I had any habits to share as an app developer.  I said:

My app developing habit … is get a new passing unit test every day.  [...] that new green dot is my indication that I’ve at least added a little bit to the application.

This is a habit I started in earnest when I took B. J. Fogg’s Tiny Habits course. My tiny habit was to just run the simulator, and the best way I found of doing that was to run the tests through it. Then, writing a new test for whatever functionality I was planning next just seemed to be the perfect way to extend it.

Once I write that first test, I don’t TDD the rest of the way, but I’ve found that first test to be a good way to warm up.

Habits 2.01 – Start Small

When I announced Habits 2.0, a fellow Western MA Hackathoner, Molly McLeod, reminded me of BJ Fogg and his Tiny Habits method.

Only three things will change behavior in the long term.

Option A. Have an epiphany
Option B. Change your environment (what surrounds you)
Option C. Take baby steps

I had first learned of BJ from Ramit Sethi’s interview with him. The moment I remember most clearly was his method to start to floss. He suggested that you only commit to flossing one tooth each day — if you did that to start and internalized that that was success, you’d start flossing more eventually. I started doing this, and while I’m not a perfect flosser, I do floss most of the time. That convinced me that baby steps were a real thing. If you have any interest in this, sign up for a (free) week-long tiny habits session with BJ.

So, with Habits 2.0 out the door, I am going to plan 2.01, a baby step improvement of 2.0 by just doing a very small amount of work each day on it.  I joined BJ’s tiny habits for this week and he recommends adding a 30-second behavior triggered by something you will definitely do each day. I decided that once I put my dinner plate in the dishwasher, I will sit at my desk and run the Simulator. Then, I will celebrate that as a success (and mark it done in Habits, of course).

I have been doing that for about 6 days, and each day when I run the simulator, I usually test Habits out a little, and write up a Trello card or write a small test.  BJ’s advice is to keep it completely pain-free and small and to not worry about building on the tiny behavior. Still, in this time I have managed to make a bunch of small improvements to Habits, which I look forward to sharing soon.

Habits 2.0

Back in 2008, I made a simple iPhone app called Habits to help me remember to do some recurring tasks that were not a regular schedule. I made a few updates early on, but it basically did what I needed it to do, so it’s been a while since I have looked at it.

Habits App IconA couple of weeks ago, I decided to refresh its look in anticipation of iOS 7. Unfortunately, an app compiled with iOS 6 doesn’t automatically pick up the new look — at the very least, you need to recompile. Instead, I decided to design something custom that would look good now and feel at home on iOS 7. While I was at it, I updated the icon using the iOS 7 app icon grid.

You can see some screen shots on the Habits documentation page, and if you want to buy it, Habits is 99 cents on the App Store.

Here’s a full list of everything that I had to do for 2.0 in case you’re a developer with an older app and want to see what you might be in for.

  • Converted to an ARC app
  • Moved lots of properties to auto-synthesize
  • Updated deprecated APIs to iOS 6.0 versions
  • Skinned the tables, mostly with custom cells
  • Added a pan gesture to the front-page cells (try moving them to the left for a short-cut)
  • Supported local notifications and badges (requiring a new settings page)
  • Made a new icon
  • Updated my Google Toolkit unit testing to Xcode built-in unit testing (which was gratefully, very easy) — the main issue is dealing with unit-testing’s idea of the document folder
  • Updated all button and default images
  • Updated in-app help
  • Converted my svn repository to git
  • Added database migration to support the settings (this app uses sqlite API directly)
  • Refactored a lot of code, mostly in the database, view controllers and custom cells, to share more code.
  • Fixed a bug in the calendar to support iPhone 5 size better.
  • Updated App Store listing, web page, made this post, etc.

Start Habits not Resolutions

I saw this list of New Year’s Resolutions on the Did I Get Things Done blog (originally from Amazon)

  • Lose Weight
  • Get Your Finances in Order
  • Go Greener
  • Curb Your Vices
  • Get in Shape
  • Relax More
  • Pursue a New Career
  • Upgrade Your Technology
  • Organize and Optimize
  • Start a New Hobby


The main reason that I have had a problem with a resolution is that I don’t really think about them much a week or so after New Year’s. A few years ago, I created a small web app for myself to log how well I was doing at keeping to resolutions I was making. A few months ago, I ported it to the iPhone as
Habits.

Instead of making resolutions this year, I created a few habits instead. I want to lose some weight this year (the #1 resolution), so I added a habit to run every 2-3 days, to do bicep/chest and shoulder/tricep weight training once a week. I want to keep my house in better order, so I added a habit to clean up and to process my mail pile more regularly.

A lot of these resolutions should just be a recurring task that you try to do as often as possible.

Habits on Sale for $0.99 until the end of January

Habits is the perfect application to make sure that you stick to your New Year’s resolutions, so from now until the end of January, I am putting Habits on sale for $0.99.

I am working on version 1.1, and I will post it at the end of January and return it to its old price. Until then, here’s hoping that you’re able to turn your resolutions into habits.

(The AppStore takes time to fully update — please make sure it says that the price is $0.99 before you buy)

Buy Habits on the App Store

How I use Habits

Habits was released last week, but before that, I had something like it on a private area of my website for me to use. This is what my Habits looks like right now (edited for brevity and to remove personal data):

Generally, I use Habits to help with Sharpen the Saw type of tasks — things I want to make sure I do every once in a while, but not necessarily at a specific time. Also, unlike a recurring event in a calendar, I can record how well I do with them (if I do them late, early, or skip them).

Announcing Habits

I have been working on my first iPhone app for the last few weeks. It is a GTD companion application to help with recurring to do items with an indefinite schedule. It’s called Habits, because I think it will help you form (good) habits. Soon to be available on the App Store.