Friday, 22 November 2013

Ruby Koans Meditation

Even if you never ever plan to code in Ruby, do check out the Neo Ruby Koans meditation.

It is the cutest, most fun programming course I've ever took.

But be sure to study the Tao of Programming first.


Thus spake the novice programmer:
``It is time for me to begin.''


Thursday, 21 November 2013

Why I don't use a smart phone

Of course I own a smartphone.  Just that it's not a phone (I have an (ancient)(lightweight) Nokia for this task) but my Apple only does 3 things that are useful to me:

1) work as a timer and reminder
2) enable me to take cooking recipes I find on the web into my kitchen
3) play the odd mp3 over the small speaker as a bedtime story

Other than that, the screen is too small to comfortably read or do anything on, and whilst I could get a bigger model, the small one I have is already too heavy to lug about as is, and, a larger screen would still be too small.

Don't you get bored just sitting around, say, waiting for Godot or on other occasions?

Nope, because my brain is a far more useful and interesting device than a smartphone, and if I really am in idle input mode, I have a tiny little Samsung U5 so I can listen to audio books.  This little toy weighs 28 grams and I can tuck it anywhere into my clothes.

Also, I quite like just sitting somewhere and looking at the world pass by, giving my mind the free run of my brain to grep for interesting things in my thoughts I've been unaware of so far.

If you do not have idle time for your brain to run riot in, it kills your creativity -- 'boredom' is the best inspiration because your mind hates a void and will find a way of entertaining you with ideas, the moment you give your mind time and space to talk to you.


It's a different kind of apple... :)

Saturday, 16 November 2013

--invoke-diff3-cmd branch ready for review




Finally the feature --invoke-diff3-cmd for Subversion is ready -- 23 files in 8 directories, 86 code snippets for a total 782 lines of code, 53 log message components plus a BRANCH-README file.

Friday, 15 November 2013

Fayzah Ahmed & Band

I'm not sure what I admire most about this video:



The VOICE.  So beautiful, so skilled, so much feeling.

The dress.  When singers still had taste.  And decorum.

The band.  Is there an instrument missing?  And they READ! 

The musicians.  The concentration and volta is wonderful.  Plus, they dress like gentlemen.  With class.

The crowd.  They are WILD!

The stage decoration.  Wish I had that in my living room!

Ok, I admit this is is probably a little uncomfortable to listen to if you're used to a western scale, but once you've wrapped your eardrums around the scale... it's simply gorgeous, and given that not even Zappa and Bird surprise me anymore with their music, I'm much appreciative of the fact that I cannot anticipate this music, and every note is still a surprise, no matter how often I listen to it. 

Sunday, 10 November 2013

Making sure I stay lucky



After nearly losing all my work yesterday, I've made this little script to run in the Emacs compile buffer before the make command.  This runs svn diff every time I compile and puts the result into a separate directory.

#!/bin/sh
CURRENT_DIR=`pwd` 
DATE_MARKER=$(date +%Y%m%d%T) 
SECURITY_PATCH_DIR=/home/g/security_patches/ 
WHAT=`echo "${CURRENT_DIR##*/}"`
EXT=.patch
SECURITY_DIFF=${SECURITY_PATCH_DIR}${WHAT}${DATE_MARKER}${EXT}
SVN=/home/g/InstalledSVN1.9/subversion
$SVN diff > $SECURITY_DIFF 

Saturday, 9 November 2013

Why checkpoint commits are a good idea...

[12:11] <gbb> idea:  [c/sh]ould merge automagically take a security diff before merging, just to protect the clumsy from their foolish mistakes?  (I merged my working copy instead of my test dir in gdb, oww, repairable but ugh...)
[12:12] <stsp> gbb, you mean something like merge --dry-run?
[12:13] <stsp> with such things, it's tricky: if we do a check by default, one set of people will complain about the additional overhead, while the other group will complain about the need to specify an option to get the safe behaviour
[12:13] <gbb> hrm dry-run would have helped but not protected me from merging over all my work.  ;(  (luckily my emacs is my handbag and most of those files were still open)
[12:14] <stsp> i think it's the type of mistake that you just need to learn to avoid over time
[12:15] <stsp> if we had checkpoints implemented, you could checkpoint your working copy before a merge, to keep a record of the pre-merge state
[12:15] <stsp> i think that would be a nice solution
[12:16] <stsp> merge could automatically create such a checkpoint, in fact!
[12:16] <gbb> not sure what check points are.  but currently you can only revert to pristine, not to pre-merge
[12:16] <stsp> see http://subversion.tigris.org/issues/show_bug.cgi?id=3626
[12:17] <stsp> or shelving, even
[12:19] <gbb> that would be the ticket :)
[13:20] <ASFBot> gbg * r1540299 (subversion/branches/invoke-diff-merge-feature/ (14 files in 6 directories)) http://svn.apache.org/r1540299 : On the invoke-diff-cmd-feature branch: Checkpoint commit (ignore, trivial).
[13:32] <gbb> as Mr. Twain remarked: "A man who carries a cat by the tail learns something he can learn in no other way."
[13:32] <stsp> :)

Wednesday, 6 November 2013

My day/week/month is made!

Julian Foad said:

"Your BRANCH-README file <http://svn.apache.org/repos/asf/subversion/branches/invoke-diff-cmd-feature/BRANCH-README> is a fantastic window into the branch, much more detailed and helpful than the rest of us ever write. I can easily see exactly what the whole feature does, how it's structured, and what your plans are, without having been paying close attention. I'm mentioning this mainly so anybody else contemplating taking a look at this knows this is a good place to start reading. And I'm pleased to see you have taken care to adhere to our coding style. "

It's the most wonderful compliment I've heard in years :)

{And, to be honest, writing this BRANCH-README helped me a lot in getting things done and keep me focused on what I was (and am) trying to do.  It was danielsh who suggested that I should write one (ironically I initially omitted it, despite fixing a part of the hacking guide entry for this most excellent advice.)}

Don't delay, write _your_ BRANCH-README today!