Bash completion for cake files

November 1, 2011

Published: 2011-11-01

To implement bash(1) tab completion for Cakefile task names all you need to do is add this completion function and command to your ~/.bashrc file:

Read the rest of this entry »

Testing CoffeeScript apps with Selenium

October 25, 2011

Published: 2011-10-25

This blog entry describes how to write functional tests for CoffeeScript web apps using Selenium. By way of example I’ll describe how I added Selenium tests to the Routeless Backbone Contacts tutorial app and automated it’s execution with a Cakefile.

Read the rest of this entry »

Compiling CoffeeScript with Vim

October 20, 2011

Published: 2011-10-20

You can configure Vim to automatically compile CoffeeScript files when you save them from within Vim, it’s easy, just add an autocmd to run the CoffeeScript compiler to your ~/.vimrc file:

Read the rest of this entry »

Getters and Setters for Backbone Model attributes

October 16, 2011

Published: 2011-10-16

The Backbone.js Model class provides get and set methods to read and write Model attributes which is not a concise or natural as object property access. But it’s not difficult to add a class method to generate Model getter/setter properties so that you can do this in CoffeeScript:

person.name = 'Joe Bloggs'
ph = person.phone

instead of this:

person.set {name: 'Joe Bloggs'}
ph = person.get 'name'

Read the rest of this entry »

Routeless Backbone Contacts 2.0

October 2, 2011

Published: 2011-10-03
Updated: 2011-10-25

This post describes a revamped version 2.0 of my original Routeless Backbone Contacts application. The material covered here builds on the original post.

  1. The basic application functionality and the underlying data remains the same.
  2. The new user interface is a single two-pane page with a selectable list of contacts on the left and contact details on the right.
  3. A Search box has been added to incrementally filter the list of displayed contacts.
  4. The application is 100% event driven — there is no direct coupling between the views. Backbone.js events emitted by the underlying contact data collection ensure the views are updated automatically when the state of the underlying data changes.

Read the rest of this entry »

Routeless Backbone Contacts

September 22, 2011

Published: 2011-09-24
Updated: 2011-10-03

You don’t need a URL router to write client-side applications.

Routeless Backbone.js Contacts is a totally client-side CRUD tutorial application written using CoffeeScript, Stylus, Backbone.js and jQuery which are a perfect match for writing concise, readable well structured web applications.

  • The source is on Github.

    Note

    This release described in this post is at the 1.0 tag.
  • Uses DOM events exclusively for UI navigation.
  • The contacts data is persisted locally using browser Web Storage.
  • Templates are written using Underscore.js templates (included with Backbone.js).

Note

A second version of this tutorial application [has been posted], it builds on the material covered in this post.

Read the rest of this entry »

Switching from the iPad to the Asus Transformer

August 31, 2011

Published: 2011-08-31

My blogs are usually technical in content and try to be objective in character, this blog is a bit different, it has an unashamed subjective bias (you’ve been warned).

Shortly after the iPad 2 was released I went over to the Dark Side and brought one (my first and only Apple computer). I was just fed up waiting for a decent Android tablet. At the time my only requirements were a decent ePub reader and a web browser.

Read the rest of this entry »

Fossil Backend for AsciiDoc

August 30, 2011

Published: 2011-08-30
Updated: 2011-09-04

Note

The Fossil backend is now hosted at Github.

Here is an AsciiDoc configuration file that can be used to create a simple backend plugin for generating Fossil friendly Wiki markup from AsciiDoc source (I wrote it as a proof-of-concept of the new AsciiDoc backend plugins).

Read the rest of this entry »

Keeping a lid on Mobile data

July 17, 2011

Published: 2011-07-17

How to configure your Android phone to automatically turn off the mobile data connection once your mobile data limit is reached.

Read the rest of this entry »

Using an iPad to access remote Windows desktops

July 16, 2011

Published: 2011-07-16
Updated: 2011-07-26 (added Q&A)

I went from initial scepticism, when I started looking for a usable iPad remote desktop solution for accessing Windows PCs, to (almost) wild enthusiasm.

I evaluated four of the best iPad remote access apps and am delighted to have found one that does exactly what I want. This post outlines why I settled on Jump Desktop along with a few usage tips.

Read the rest of this entry »


Follow

Get every new post delivered to your Inbox.