Archive for March, 2010

A Request for Android, Tim Bray, and Google

2

Mr. Bray has joined the empire of no evil, the Android group no less, and has been writing useful things about Android and Nexus One. He also has deep roots in the world of scripting, has been an advocate, and has been fearless in his experiments with languages new fangled and old.

So I’d like to make a request of Tim, one that I think would make a tremendous impact. Tim: please help bring scripting to Android development.

I know that a lot of people like Java and find the current development environment just dandy. Which is great. But many other reasonable people would prefer to keep their hands clean of Java and feel a greater degree of productivity using higher level languages.

Imagine a scenario where you could write a Python, Ruby, or Javascript script, get it onto the phone using a simple interface (eg. just upload it to a url), and have a native app. Imagine how many more people would be developing apps, and how much more quickly.

I’m looking for something like this: supported and documented as a standard part of the Android SDK, all reasonable APIs needed to develop native apps exposed as Javascript (and/or Python or Ruby, but Javascript is likely the widest reaching bet). And a reasonable packaging process that is only slight more complex than tar.

There is absolutely no reason this can’t be achieved. In fact projects like Appcelerator and PhoneGap have already made tremendous strides in this direction. All it takes is a believer to take the initiative and make it happen.

I feel Tim is that believer. And so I humbly submit, Mr. Bray, that the most important impact you could have on Android is to embed a love and support of scripting languages into the SDK. Pretty please.

How To Use curl To Upload a File While Limiting Bandwidth

0

For future reference:

I needed to simulate a slow connection for testing an HTTP file upload, time the results, and see how reliable it was. Turns out it’s all doable with curl using the right set of incantations. Here they are:


curl -F file=@/tmp/sample-large-image.jpg -F some_parameter=1027504 \
    -u myusername:mypassword -w "\nTIME: %{time_total}\n" \
    --limit-rate 10k http://somewebsite.com/api/upload/

What this is saying is:

  • Upload the file /tmp/sample-large-image.jpg . Note the “@” symbol – that’s what tells curl this his a file upload.
  • Set the parameter some_parameter to 1027504
  • Use HTTP basic auth to login, with user “myusername” and password “mypassword”
  • Include the word “TIME” followed by how long the upload took in the output
  • Limit the upload bandwidth to 10k bytes per second

curl continues to amaze with its flexibility.

12 Surefire Ways To Get Retweeted And Increase Traffic

0

Excuse the bullshit title, I’m just a little bit sad right now that my RSS feed is filled with “19 ways to do this” and “7 tricks of the other”. Are we ever going to move beyond this tripe or is this the confirmed future of the web?

Anyway, the point of this post, if there is any, is to reveal to you the secret of getting traffic to your blog and of adding twitter followers. Ready? Here it is:

You should write blog posts. And tweet.

There is no further secret that I’ve been able to figure out.

Take, for example, my recent post on How To Be A Good Participant On A Panel. It’s brilliant. Go read it. I’ll wait.

That post got tweeted a number of times, including by Dave McClure, one of the most interesting guys in the startup world, and it got a link from Simon Willison, whose link blog is the single best resource for finding all things of interest in the web/tech world.

I am pleased.

Now let me tell you about that blog post. It took about 45 seconds to write, and I came very close to not publishing it. It is, after all, just a little puff of air.

I have at other times written important, interesting, thought provoking masterpieces and even made some effort to get them noticed. Yet, as often as not, they fail to garner any interest.

My Become an Assassin post, however, still gets quite a bit of traffic (from people who actually want to become assassins).

Go figure.

Which is to say, there is no figuring it. When it comes to blogging or tweeting, the best policy is to not worry about it and just write whatever interests you, no matter how earth shattering or inconsequential it is. Resist the urge to censor yourself; just push publish.

How To Be A Good Participant On A Panel: Disagree

1

Mark Suster and Fred Wilson have both posted on the topic of being a good panelist. I’ll throw in the best advice I ever got on the topic (from Alex, who got it from someone else):

Disagree with other panelists.

A panel of people agreeing with each other is generally tremendously boring, and any topic that’s interesting enough to be brought up as a question to panel must have at least two sides that can be argued.

So argue the other side. Find someone else on the panel willing to go toe to toe with you, and disagree with what they say. The point is not to start a fight, but to create an engaging discussion. It’ll force you to think on your feet and it’ll entertain the audience.