The Minitest Cookbook

I’m not a professional developer (at least not as of 2017-01-26), but I’ve always been enamored with the idea of testing. The first time I jumped into testing, I went straight for the Rspec/Cucumber stack. Rspec seemed to be the thing that all the serious developers used, and Cucumber seemed like an interesting way to write tests. I tried both. Rspec is a fine system, but it can feel overwhelming at times. There are almost too many options. Cucumber can be a good way to go, if you need to develop...

Read more…

Sed and Awk Shebangs

#!/bin/bash

sed 's/some pattern/something else/g' $*

…is bad form, in my opinion.

#!/usr/bin/sed -f

s/some pattern/something else/g

…seems so much better.

#!/bin/bash

awk '/some pattern/ { print }' $*

…is bad form, in my opinion.

#!/bin/awk -f

/some pattern/ { print } 

…seems so much better.

Read more…

Hunger and Guides

There’s a lot to be said for turning the tasks in your productivity system into guides. Instead of checking OmniFocus to see if you need to wash the dishes or do the laundry, you’re better served by taking notice of the dishes or clothes that are piling up and then acting on that guide. After considering the role of guides vs. tasks, I’ve found there’s been a great weight lifted off of me in regards to task management. I used to have silly tasks popping up in my OmniFocus Dashboard every day....

Read more…

Fixxxer: AppleScript to Set and Clear Prefixes in OmniFocus

Another nifty script for OmniFocus. It’s called Fixxxer. It does two things. If you run it with no arguments, it will remove colonized prefixes from task names. If you pass it an argument, it will add that argument as a prefix to selected tasks. It’s LaunchBar-ready. If you want to turn off the confirmation dialog, set nagMePlease to false.

use AppleScript version "2.4" -- Yosemite (10.10) or later
use scripting additions
use O : script "omnifocus"
use OmniFocus : application "OmniFocus"
-- If...
Read more…

Considered: AppleScript to Wrangle Considered Tasks in OmniFocus

I wrote another cool little tool using my AppleScript library. It’s called Considered. It also handles things having to do with colons and prefixes, but specifically the Consider: prefix. If you’re unfamiliar with considered tasks, read all about them here. Instead of trying to set task names to something like “Consider reviewing” with the ing, I opted for Kourosh Dini’s prefix-style considered tasks where you just add Consider: as a prefix. It’s simpler and easier to script. Here’s the code ...

Read more…