April 2010
7 posts
Pretty-printing JSON
Andrew Wooster / @wooster:
Tip of the day: pipe JSON to python -mjson.tool for pretty indenting.
Nice tip. I also like http://jsbeautifier.org, whose source is on github if you want to clone it down and run it locally.
March 2010
19 posts
1 tag
mogenerator 1.17
What’s New:
[NEW] +[Machine entityName] (for @drance) and +[Machine entityInManagedObjectContext:] (Michael Dales).
[NEW] Add --orphaned option. (rentzsch)
Couple it with --model to get a listing of source files that no longer
have corresponding entities in the model.
The intent is to be able to pipe its output to xargs + git to remove
deleted and renamed entities in one command,...
2 tags
Retroactive Git Branching
I kind of backed myself into a corner with mogenerator.
Back in January I added a couple of features to my local copy, but foolishly didn’t push them upstream. Then I proceeded to undergo a significant refactoring but got interrupted before completion.
Fortunately I was able to retroactively create a branch representing my committed-to-master-changes and migrate them to a new...
Faith-Based Casts
This post merely serves to better record Matt Drance’s term, “faith-based casts”. Like pouring a new driveway, I expect it to enter my vernacular.
Matt Drance / @drance:
@mzarra @iamleeg I don’t know, I find e.g.(NSHTTPURLResponse *)response much more disturbing.
Marcus S. Zarra / @mzarra:
@drance @iamleeg the delegate will accept id (or NSHTTPURLResponse) just...
1 tag
ClickToFlash and Flash Block Detector
I just dropped ClickToFlash 1.5.4 which fixes YouTube’s “Old Flash? Go upgrade!” message in the 1.5 branch (it’s been long-fixed in the 1.6 branch).
With this release, both 1.5.4 and 1.6b8 now advertise their presence (and version) via Javascript. This is mostly to assist Mark Pilgram’s Flash Block Detector project.
To use ClickToFlash’s new feature, call...
2 tags
Recipe: Install Mercurial 1.5 from source on...
Debian Backports is still handing out Mercurial 1.3.1. I wanted to try out 1.5 server-side, which wasn’t hard:
$ wget http://mercurial.selenic.com/release/mercurial-1.5.tar.gz
$ tar xfz mercurial-1.5.tar.gz
$ cd mercurial-1.5
$ apt-get install python python-dev build-essential
$ make install-bin
The main issue was figuring out I needed to install python-dev to get the C headers mercurial...
Accenture: Tiger: "I am deeply sorry"
I snapped this on Accenture’s large screen display at O’Hare heading out to NSConf US:
Purrfect.
SafariSessionSaver 1.2
A couple of years back I lazytweeted for an app that would archive my open Safari window URLs. After not getting back a satisfactory answer, @gruber said I should just write it myself already.
So I did.
I just pulled the project over from my old svn repo to github and revved it so it also saves tab URLs (previously, they were ignored).
It’s an intensely dumb app, and could be improved...
1 tag
Apps I Love: LicenseKeeper
I used to keep my serial numbers in a simple text file. But I’d fall behind in keeping it up-to-date, and inevitably have to resort to searching my inbox whenever I’d need a serial number again.
But things got better when I bought Jon Trainer’s LicenseKeeper.
It’s actually fun now to import serial numbers, so I always do it.
It’s fun to drag the app into...
Productivity.app
It occurs to me I can gauge a day’s productivity by which apps I don’t launch:
NetNewsWire: A man with a plan.
Mail.app + NetNewsWire: On a deadline.
Twitterrific + Mail.app + NetNewsWire: Consumed with an idea.
2 tags
Random Cappuccino Tips
Need a small progress indicator? Sadly CPProgressIndicator only does 64x64. Check out EKSpinner if you need a full-scale solution, otherwise just borrow the spinner.gif that’s already included in each Cappuccino app resources folder and stick it into a CPImageView that you show/hide based on activity. (It’s 16x16.)
Unfortunately Cappuccino’s online docs are rather outdated, so...
1 tag
Recipe: CloudKit
CloudKit is Jon Crosby’s neato web app that vends schemaless-but-versioned JSON objects via a RESTful web API.
In short, it’s a fast+easy+cool way to bootstrap your site’s backend data model. Boot CloudKit, and start writing your Ajax calls against it immediately. Morph your data model as you write the app’s code and figure things out.
Once things settle down and you...
2 tags
No Other Distribution Authorized Under this...
Apple’s iPhone Developer Program License Agreement:
7.3 No Other Distribution Authorized Under this Agreement
Except for the distribution of freely available Licensed Applications and the distribution of Applications for use on Registered Devices as set forth in Sections 7.1 and 7.2 above, no other distribution of programs or applications developed using the Apple Software is...
5 tags
Mercurial: Abort/Broken Pipe Error
If you’re getting an abort: error: Broken pipe error when pushing a largish changeset:
$ hg push
pushing to http://user@example/hg/project
searching for changes
abort: error: Broken pipe
Then it’s probably due to issue 2716, which has already been fixed by coding rockstar Augie Fackler. Rock on, Augie.
Upgrade your Mercurial version — the just-released v1.5 does the trick...
1 tag
ClickToFlash 1.6b7 solves YouTube's "Old Flash? Go...
[Hi TUAW readers, as I mentioned in a comment: ClickToFlash version 1.5.4 is about ready to go out, which rolls in 1.6b7’s YouTube fix. It will be available via the normal Sparkle upgrade channel, so it’s cool if you just want to wait for the auto-update.]
If you want a great concrete example of how open source rocks, look no further than ClickToFlash’s “Old Flash? Go...
1 tag
Apps I Love: MoneyWell
This year I jumped from Liquid Ledger to MoneyWell for doing my taxes.
It was a bit of a leap of faith, but it turned out well — MoneyWell is simply the best personal finance app I’ve ever used.
※ ※ ※
I dismissed MoneyWell 1.0 a while back based on its design decisions (a shallow reason I know, but the field is littered with non-native or just-plain-weird apps and painful...
The British Junk Food Report
The absolute most-important thing for a U.S.-based traveler to the U.K. is knowing what junk food you should load up on while there. Here’s our report:
Mars: DON’T BUY. I could detect a difference, but not “oh wow” better enough to justify the calories.
Twirl: DON’T BUY. Cadbury bills it as “The Intense Chocolate Hit”, but it’s easily our...
7 tags
Recipe: hgwebdir on Debian 5 Lenny
There’s a bunch of different ways to publish Mercurial repositories, but I like hgwebdir. It handles multiple repositories with a nice-enough UI.
What’s slick is that http://example.com/hg/myproject will be the url for both humans to inspect (view history, tags, branches, etc) and the url you’ll hand to hg clone.
These are the best instructions I found for setting up...
Sirius Sucks
Looks like Sirius is going to make it:
Sirius XM Radio Inc. posted its first quarterly profit since its merger and said it expected to add 500,000 new subscribers in 2010 as the recovery in the car market boosts demand for satellite radio.
(via Gruber)
It’s a shame — I had hoped they’d go out of business, after how they treated me as a customer.
※ ※ ※
About two years...