my name is Leon.
I write code on the bus every day.
the chubby guy getting on the bus is *not* me though people have been kind enough to put out that he looks like me. cheers.
I get 10 - 20 mins each way,
most days of the week.
Don't try to be a hero
This guy is trying to be optimus prime. But he's over reaching.here's the computer I use
it's a HP-mini with lots of stickers on it. i got the HP as an attendee at Tech Ed australia 2009.With support crew
here's what I've produced,
on the bus,
in the last year:
+ also (in recent days)
this slide deck presenter (higgins)
a csv to json app
'OnTask'
various TiddlyWiki hacks
a bit of other stuff off the bus: zo, fuv, some timesnapper updates (though not enough), sysi, fracback, a few upgrades to nextaction and many unpublished works including Nextaction-berzerker.
Toxic Environment => Max Productivity
Why?
To me, this is kind of amazing.
a terrible development environment has become something very productive.
Any lessons?
Further optimizations?
So I want to go through what I've done here, to see if there's some kind of general lessons we can take away.
And I'm keen to hear any further optimizations you can give me.
Developing on the bus has a lot of limitations...
Netbook has:
Bus is:
Limits increase creativity.
Every problem has either been overcome or turned into an advantage.
Biggest Problem === Biggest Advantage
A good thing or a bad thing?
No internet is a good thing.
Distractions kill productivity.
Q: What is the internet good for anyway?
Q: What is the internet good for anyway?
A: Answering questions.
Q: What is the internet good for anyway?
A: Answering questions.
1. Aim to have less questions.
Q: What is the internet good for anyway?
A: Answering questions.
1. Aim to have less questions.
Q: What is the internet good for anyway?
A: Answering questions.
1. Aim to have less questions.
2. Get offline resources.
JQuery Api for offline browsing
The point here is that a good reference can save you time -- but even still it takes time and clicks and waiting to get to the bit you want. You could waste a whole bus stop on a thing like this.
Ruthless devotion to simplicity.
Taking on a few dependencies is a slippery slope.
less moving parts. less abstractions. less dependencies.
All Abstractions leak.
Use less of them.
ASP.Net web forms:
Abstraction built far up above Html/Http.
ASP.Net MVC
Still leaks! But closer to the real thing.
(so less 'jarring' when it does)
SQL
Abstraction over ISAM (?)
Rarely leaks.
SQL
Even it leaks into lower abstractions...
You can't remain ignorant of indexes.
You can't remain ignorant of locks.
Example of ruthless simplicity:
Database:
License management for TimeSnapper
Database:
License management for TimeSnapper: 5 tables
Customer has Licensetype has Licensedproduct has Customerpurchase has Purchasedlicense
ASCII ERD FTW!
Database example:
License management for NimbleText: 3 tables
Products has Purchases has ActivationAttempts
even here -- i could cut it down to 2 tables. Why bother having a 'products' table when the whole system is set up for selling just one product? That's classic over-engineering.
If a 5 table system can be simplified down to 2 or 3 tables:
Have far could we simplifiy the 500+ table systems we deal with in our jobs?
Love jquery, but when possible I just use:
The poor man's jquery.
The poor man's jquery:
function $(ID) { return document.getElementById(ID); }
javascript: only use 'the good parts'
javascript: only use 'the good parts'
+ eval.
javascript: only use 'the good parts'
+ eval.
"eval is evil?"
javascript: only use 'the good parts'
+ eval.
"eval is evil?"
Awesome!
Crowd interjection by Andrew Harcourt at this point steered me towards:
new Function("alert('Hello, world!');")();
demo: unit testing 'framework' built into nimbleText
.debug { display: none; }show it... then change it to block. now there is a little cheaty area at the foot of the page. there's a button for 'run unit tests' i click it -- it runs, and hopefully it turns green. each test is output. the tests themselves are 'data-driven' -- as that's the kind of app I'm using. if i think of, or hear of a situation that doesn't work -- i put the input in, run it and change the output to be what i want then i extract a new test. then show how i extract a new test.
Problem:
No Visual Studio
Work arounds...
Learn to build an assembly from scratch.
static class App { static void Main() { System.Console.WriteLine("Hello world."); } } ...\Framework\v2.0.50727\csc.exe sample.cs
Use msbuild (from notepad++) to compile projects
Use msbuild (from notepad++) to compile projects
Vaporators? Sir, my first job was
programming binary loadlifters-very
similar to your vaporators in most
respects.
ideal project size for bus development:
ideal project size for bus development:
1 file.
ideal project size for bus development:
1 file.
All javascript. html. css.
Love your tools, libraries and snippets.
Stock the pantry:
Stock the pantry:
Keep all your favorite pieces of code handy.
Stock the pantry:
Keep all your favorite pieces of code handy.
Have all your favorite little tools handy.
Stock the pantry:
Keep all your favorite pieces of code handy.
Have all your favorite little tools handy.
Keep your documentation handy.
favorite pieces of code...
function $(ID) { return document.getElementById(ID); }
using Mono.Options; // Beautiful Console argument parsing! // As used in NimbleText ... var p = new OptionSet() { { "d|rawdata=", "the raw input data", v => settings.InputData = v}, { "p|pattern=", "the pattern", v => settings.InputPattern = v}, { "i|inputdatafile=", "a filename for loading the input data", v => settings.InputDataFile = v}, { "s|pipeline", "Stream input data via the pipeline", v => settings.Pipeline = v != null}, { "f|patternfile=", "a filename for loading a pattern", v => settings.InputPatternFile = v}, { "r|rowdelim=", "the row delimiter", v => settings.RowDelimiter = v}, { "c|coldelim=", "the column delimiter", v => settings.ColumnDelimiter = v}, { "o|outputfile=", "a filename to store the results", v => settings.ResultsFile = v}, { "g|gui", "show the Graphical User Interface", v => show_gui = v != null}, { "?|h|help", "show this message and exit", v => show_help = v != null }, }; try { unprocessedArgs = p.Parse(args); }...
favorite tools:
Pick your favorites.
Know them well.
Connect to wireless at home.
Synch over LiveMesh DropBox.
favorite tools:
... favorite version control system -- Wait!
Sidebar: is a VCS necessary for single person projects?
VCS as backup system:
VCS as backup system: just use dropbox
VCS as backup system: just use dropbox
VCS as 'versioned history':
VCS as backup system: just use dropbox
VCS as 'versioned history': just use dropbox
VCS as backup system: just use dropbox
VCS as 'versioned history': just use dropbox
VCS as team-communication enabler:
VCS as backup system: just use dropbox
VCS as 'versioned history': just use dropbox
VCS as team-communication enabler: single person project.
VCS as backup system: just use dropbox
VCS as 'versioned history': just use dropbox
VCS as team-communication enabler: single person project.
VCS as tool for 'branch on feature':
VCS as backup system: just use dropbox
VCS as 'versioned history': just use dropbox
VCS as team-communication enabler: single person project.
VCS as tool for 'branch on feature': single file project.
Single person / Single file projects:
'Branching' is free. Merging is trivial.
Need real vcs (i.e. Mercurial) when:
Feature spans more than one file.
Multiple horrible changes while offline.
Working in a team.
Mercurial and DropBox can live together.
tools:
file difference tool: diffMerge.
tools:
text editor: vim
tools:
text editor: notepad++
...considering: e & sublime.
just kidding about vim.tools:
jslint, jsmin, msbuild, powershell, fsi.exe
nimbleText, Kaxaml, LinqPad, Mini SQL Query
Browser dev tools (in Chrome, IE, Firebug)
mspaint, Paint.net, colorPic
Don't be a hero.
A tiny bit of work every day is better than heroic all-nighter marathon sessions.
A tiny bit of work every day is better than heroic all-nighter marathon sessions.
Don't be a hero
Everything
else can be overcome
if you work at something *every* day.
Design the work
so you *can* do it in
20 min bursts.
Or 10 minutes.
Or 5.
#1 Internet is bad
#2 Keep it damn simple
#3 Value your tools/libraries/snippets
#4 Don't be a hero