Monday, October 27, 2014

How To Create a CLI Program Using Coffee-Script

I'll show you how to create a command line program with coffee-script.

First of all, you'll need node.js - if you don't have it installed, then head over to and install it. You will also need coffee-script:
$ sudo npm install coffee-script -g

We will call our application arg,  so let's create the project directory:

$ mkdir arg
$ cd arg
$ mkdir bin
$ npm init

The npm init command will ask you for your project info - for this demo, you can just hit enter for each prompt. This creates the file package.json, which we will edit, adding:

  "bin": {
    "arg": "./bin/arg"

Next create create the file ./bin/arg (no extension) with the following lines

#!/usr/bin/env coffee
http = require('http')
url = ""

http.get url+escape(process.argv.slice(2).join(' ')), (res) ->
  res.on 'data', (chunk) ->
    console.log String(chunk)
  .on 'error', (err) ->
    console.log err
Finally, mark it as executable and install:

$ chmod a+x ./bin/arg
$ sudo npm install . -g

Now enter

$ arg I like coffee-script
I like spiced rum-script

Spiced Rum-Script? Hmmm...

Arg follow 'tis link to github to download th' gist

Friday, October 17, 2014

The Graying of Software

Aging is one thing that affects everyone, regardless of socio-economic status or any other measure of the human condition. So seeing something like Telikin makes me feel good.

Don't mistake this for an endorsement of their product - I've never used it. I'm not recommending that you buy it. But I know that my parents would have loved something like this. They had WebTV, and as awful as that was, they enjoyed using it.

Is there other 'software for seniors'? I don't see much out there. I think there should be more thought, discussion, and action about this. Everyone of us has at least two seniors that have affected our lives. We need to give back. What applications would we write? Reminders? Memory Games? Remotes? Calculators? Almost anything can be re-tooled for senior needs. What software will you want to use when you get old and gray? Will you still be able to use it?

It's a potentially huge market, but it has a very limited budget. Our local retailers offer senior discounts. What about Google - should they give a discount to seniors? How do we verify age to make that possible?

All I have are questions. I think these are questions we should all be asking.

Monday, October 6, 2014

Selling Your Old Android Phone?

Whether you donate or sell your old Android phone, you should make sure that there is no personal information left on it. C/Net has a great how to:

But as I got to step three: Load dummy data, I thought 'How much dummy data can my phone hold?' About 12 gb, it seems. That sounds tediuos - what are the chances that I'll actually finish copying 12 gb of dummy photos to my phone? Where am I going to get that many dummy photo's? And aren't photo's going to automatically post to Google+? Agh.

Of course, there is the advice 'take a hammer to your phone' ... So I wrote an app to do it for me

Data Hammer

And it's free on Google Play:

Get it on Google Play

Data Hammer fills up your phone's hard drive with random bytes. I've tested it on our phones -

  • Nexus 4 running 4.4, both Dalvik and ART
  • Samsung S4 running 4.3

And it is tested in the emulator to be compatible back to version 2.2 Froyo.

Please report any issues on github