<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description>I’m a nerd and I like food, expect recipes written in pseudocode. I also like to doodle. And waflle on about lovely things like life - that’s pretty good!</description><title>oodavid... what a blog you have!</title><generator>Tumblr (3.0; @oodavid)</generator><link>http://oodavid.tumblr.com/</link><item><title>Prove you can program... Fizz-Buzz!</title><description>&lt;p&gt;&lt;span&gt;After reading &amp;#8220;&lt;/span&gt;&lt;span&gt;Imran on Tech &amp;gt; U&lt;/span&gt;&lt;a href="http://imranontech.com/2007/01/24/using-fizzbuzz-to-find-developers-who-grok-coding/"&gt;sing Fizz-Buzz to Find Developers who Grok Coding&lt;/a&gt;&lt;span&gt;&amp;#8221; I felt the urge to quickly doodle a Fizz-Buzz program or two.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;For those who haven&amp;#8217;t jumped on that link I&amp;#8217;ll redact the article:&lt;/span&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;People with Computer Science degrees fail at simple Programming tests - which makes it a bitch to hire someone decent.&lt;/p&gt;
&lt;p&gt;Separate the wheat from the chaff by asking them to program the childs game Fizz-Buzz for 1-100 on paper.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;He says that it should take a couple of minutes, and that he&amp;#8217;s seen senior coders take TEN to FIFTEEN minutes to do this. Personally I think this is a 1-minute task. So here goes&amp;#8230;&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/66b9fab2196d6eeec0393d64bc6b2a57/tumblr_inline_mkq5q4ZK9s1qz4rgp.jpg"/&gt;&lt;/p&gt;
&lt;p&gt;1m 5s - not too bad, this is how I reckon it broke down&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;5s - double check the rules: fizz=3, buzz=5&lt;/li&gt;
&lt;li&gt;15s - code the thing in my head&lt;/li&gt;
&lt;li&gt;45s - grab my archaic quill and realise that pens are bloody slow&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;I think a better question might be &amp;#8220;given 15 minutes&amp;#8221; how many different ways could you write Fizz-Buzz&amp;#8230;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/47445606511</link><guid>http://oodavid.tumblr.com/post/47445606511</guid><pubDate>Mon, 08 Apr 2013 10:00:21 +0100</pubDate></item><item><title>My new Office, thanks to Ignite100</title><description>&lt;p&gt;Working at home is a mix of awesome and loathsome.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;On the plus side&lt;/strong&gt; there is no commute, I can cook anything I like for lunch &lt;em&gt;(a massive bonus for me)&lt;/em&gt;, I have peace and quiet, my office toys (projector, sound-system, whiteboard etc) get to be my cinema and party-fodder and my actual toys (mostly nerf guns and puzzles) get to be my distraction while &amp;#8220;compiling&amp;#8221;&amp;#8230;&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://imgs.xkcd.com/comics/compiling.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Negatively speaking&lt;/strong&gt; you find yourself cracking at the seams for want of good company, even for just a bit of lunchtime craic, there&amp;#8217;s also the astronomical utility bills and the fact that my lunchtime would regularly drag on for 2 hours - &lt;em&gt;&amp;#8220;I started early this morning and will make up for it this evening, I can justify a couple of episodes of X-Files with my lunch.&amp;#8221;&lt;/em&gt; Again.&lt;/p&gt;
&lt;p&gt;I think it was this shitty extended winter that did it, but I decided to fire off a tweet &lt;span&gt;for a desk to rent and received a &lt;em&gt;&lt;strong&gt;very&lt;/strong&gt;&lt;/em&gt; swift reply from &lt;/span&gt;&lt;span&gt;&lt;/span&gt;&lt;a href="https://twitter.com/paul_a_smith"&gt;Paul Smith&lt;/a&gt;&lt;span&gt; - why yes, I &lt;em&gt;would&lt;/em&gt; like to take the last remaining desk in an office full of people I know and admire.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;The &lt;/span&gt;&lt;a href="http://ignite100.com/"&gt;Ignite100&lt;/a&gt;&lt;span&gt; office is a splendid space in central Newcastle; it houses startup companies on their &lt;/span&gt;accelerator&lt;span&gt; program. Successful companies are encouraged to stay in the area and rent space from Ignite. The end result is an ever growing community of likeminded, driven people. They also rent a few desks, boon to me!&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Ignite100&amp;#8217;s business model is simple and exciting, when the penny dropped I felt awed. By keeping hold of these successful businesses they are creating a sort of economical critical mass, and like any large body it will only serve to pull in more and more businesses. Good for their books, good for the region, and good for lonely nerds like me.&lt;/span&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/46941598723</link><guid>http://oodavid.tumblr.com/post/46941598723</guid><pubDate>Tue, 02 Apr 2013 16:54:00 +0100</pubDate></item><item><title>My weekend project - Molecule Match</title><description>&lt;p&gt;I like games, but I rarely get the chance to play them. My favourite are games that are hard, like &lt;em&gt;&lt;strong&gt;reeaally&lt;/strong&gt;&lt;/em&gt; hard, that make you think, that make you hurt. In business terms it&amp;#8217;s a terrible idea to ostracise your target audience to any degree, as such these games are a rare beast.&lt;/p&gt;
&lt;p&gt;At the start of the year I found myself yearning to get back to my codey roots and have a tinker with games, I spent a lazy Sunday writing and doodling about the various half-baked ideas that I&amp;#8217;ve had over the years and finally remembered a game that we played as kids called &lt;a href="http://www.youtube.com/watch?v=sAhLKcuKO1s" title="Chiral Gameplay" target="_blank"&gt;Chiral&lt;/a&gt;, man that game ticked all my boxes.&lt;/p&gt;
&lt;p&gt;In the style of a man that has a 1001 things to do I started tinkering anyhow&amp;#8230;&lt;/p&gt;
&lt;p&gt;&lt;iframe frameborder="0" height="600" src="http://www.youtube.com/embed/vBg50OvoVvA?vq=hd720" width="500"&gt;&lt;/iframe&gt;&lt;/p&gt;
&lt;p&gt;Thusfar I have created:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;A decoupled &amp;#8220;grid engine&amp;#8221; to power any number of games on grids&lt;/li&gt;
&lt;li&gt;A proof-of-concept implementation that presents a grid of atoms, each has a random valency and can be connected to create molecules.&lt;/li&gt;
&lt;li&gt;A simple scoring engine that rewards massive molecules&lt;/li&gt;
&lt;li&gt;Some intro levels that explain how to play the game (not shown in the video)&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;I plan to:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Design some different game-modes; timed, clear the board, &amp;#8220;match 3 style&amp;#8221; (where more atoms drop down when cleared etc), puzzle&lt;/li&gt;
&lt;li&gt;Make the intro levels work really well&lt;/li&gt;
&lt;li&gt;Get some music made for it - probably by &lt;a href="http://echolevel.co.uk/"&gt;Brendan Ratliff&lt;/a&gt;, possibly in the style of &lt;a href="http://youarelistening.to/deepthought"&gt;You Are Listening to&amp;#8230; Deep Thought&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Make some sexy visuals / animations - &lt;em&gt;I find this quite daunting&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Reprogram it for Android (native) and iPhone (native) -&lt;em&gt; it&amp;#8217;s currently just Javascript&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Oh yeah, and make it REALLY SWEARY. I don&amp;#8217;t know why, but I like the idea of having the avatar being frustrated by the game and pouring out a constant torrent of abuse.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Molecule? Bollecule!&lt;/strong&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/46329347671</link><guid>http://oodavid.tumblr.com/post/46329347671</guid><pubDate>Tue, 26 Mar 2013 10:57:00 +0000</pubDate></item><item><title>OOP - Method Bubbling in PHP</title><description>&lt;p&gt;Contrary to my online handle &lt;em&gt;&amp;#8220;Object-Oriented David&amp;#8221;&lt;/em&gt; I use Object-Oriented Programming very sparingly. I &lt;em&gt;do&lt;/em&gt; however try to use the right tool for the job and take on as many of the concepts that I love about frameworks and libraries I admire.&lt;/p&gt;
&lt;p&gt;In creating a &amp;#8220;query builder&amp;#8221; for the NexGen platform I ended up wanting to use syntax that I would associate with jQuery; chained and namespaced with a common bubbling of methods and properties. Thus I designed a very simple class (it&amp;#8217;s simple, but it took me about 2 hours of experimentation to make!)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Here&amp;#8217;s the code - with example&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="https://gist.github.com/oodavid/5195592"&gt;&lt;a href="https://gist.github.com/oodavid/5195592"&gt;https://gist.github.com/oodavid/5195592&lt;/a&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;In my implementation you can run queries like these:&lt;/p&gt;
&lt;pre class="brush: php;"&gt;query-&amp;gt;sql('SELECT TABLES')-&amp;gt;execute()-&amp;gt;debug();
query-&amp;gt;select('*')-&amp;gt;from('users')-&amp;gt;join('avatar')-&amp;gt;where('id', 1)-&amp;gt;limit(1)-&amp;gt;execute()-&amp;gt;debug();
query-&amp;gt;delete()-&amp;gt;from('users')-&amp;gt;where('id', 10)-&amp;gt;limit(1)-&amp;gt;execute()-&amp;gt;debug();
query-&amp;gt;upsert('users')-&amp;gt;data(array( 'id'=&amp;gt;NULL, 'email'=&amp;gt;'david@oodavid.com' ))-&amp;gt;return(TRUE)-&amp;gt;execute()-&amp;gt;debug();&lt;/pre&gt;
&lt;p&gt;&lt;span&gt;As you can see, each use execute() and debug(), lets explain what happens:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;execute()&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;span&gt;&amp;#8230;is defined on the child objects sql, select, upsert and delete&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;They each build a SQL variable and store it as a property on the parent query object.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;They also access the parents database handler and execute the query.&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;strong&gt;debug()&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;span&gt;&amp;#8230;is NOT defined on any of the child objects, thus the method bubbles up to the parent query object.&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;Since the child-&amp;gt;execute() methods set the SQL property on the parent, this common method runs an analysis of the query showing timings, &lt;/span&gt;&lt;span&gt;bottlenecks and other useful information&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;</description><link>http://oodavid.tumblr.com/post/45751100405</link><guid>http://oodavid.tumblr.com/post/45751100405</guid><pubDate>Tue, 19 Mar 2013 12:23:44 +0000</pubDate></item><item><title>A Server Monitor that Doesn't Suck - End Result</title><description>&lt;p&gt;To follow on from the last post - on Friday I quickly cobbled together a simple server monitor that I&amp;#8217;m proud to show off, it:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Looks good full-screen&lt;/li&gt;
&lt;li&gt;Shows a single metric at a time&lt;/li&gt;
&lt;li&gt;Slowly fades between metrics&lt;/li&gt;
&lt;li&gt;Highlights the severity in a way I can see in my peripheral&lt;/li&gt;
&lt;li&gt;Works on mobile devices&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;While I&amp;#8217;ve only 7 metrics up and running the basics are in place so I&amp;#8217;ll slowly add in new metrics until I&amp;#8217;ve got a complete view of the business.&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/ff97247a98714dd6a06700d7c738ff81/tumblr_inline_mjlf8kiPUA1qz4rgp.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;running on my local machine and scanning my media disk&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/3ac29bbcec295ecea0ca438b02a21d8b/tumblr_inline_mjlf8zYGas1qz4rgp.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;a useful business metric, these 2 people could represent money&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/f0450eaae03a28a810e03792dfaee50c/tumblr_inline_mjlf98OFlE1qz4rgp.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;&lt;span&gt;click anywhere on the screen to drill down&lt;/span&gt;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/1c4f555e15290240d49504f9582ae637/tumblr_inline_mjlf9tcUtG1qz4rgp.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;there&amp;#8217;s a few vanity metrics - to keep me happy and impress visitors&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;So there you have it, a server monitor that doesn&amp;#8217;t suck.&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;

&lt;p&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/45259556712</link><guid>http://oodavid.tumblr.com/post/45259556712</guid><pubDate>Wed, 13 Mar 2013 09:56:00 +0000</pubDate></item><item><title>A Server Monitor that doesn't explode your eyeballs</title><description>&lt;p&gt;I&amp;#8217;ve been looking forward to the final item on my weekly todo, so much so that all other items have been completed with gusto! Time to:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;&amp;#8220;Write a server monitor that looks effing awesome&amp;#8221;&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The rationale behind this tangential quest is that while playing with &lt;a href="http://nagios.org" title="The Industry Standard IT Monitor" target="_blank"&gt;nagios&lt;/a&gt; I can&amp;#8217;t help but think that, while functionally useful it&amp;#8217;s visually unappealing - viz. I will never look at it.&lt;/p&gt;
&lt;p&gt;&lt;img alt="image" src="http://media.tumblr.com/fd66155fc900c304036e27a47acc35be/tumblr_inline_mjadzxvFtM1qz4rgp.png"/&gt;&lt;br/&gt;&lt;em&gt;The Industry Standard - a bit ugly!&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Y&amp;#8217;see, I&amp;#8217;m used to using things like &lt;a href="http://conky.sourceforge.net/" target="_blank"&gt;conky&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Conky is lightweight linux program that renders an overlay on your desktop background image, mine&amp;#8217;s configured to show system errors, new emails, CPU usage, network load and various system variables. It&amp;#8217;s super handy because it&amp;#8217;s just always there. LIVE Errors are most important, thus I make them really pop out at me:&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;&lt;img alt="image" src="http://media.tumblr.com/fceb9a6c500924693f5e8921a8591afa/tumblr_inline_mjaeg68R3r1qz4rgp.png"/&gt;&lt;br/&gt;&lt;em&gt;Visually nicer, but limited in functionality&lt;/em&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;So my plan is to combine the functionality of nagios, the simplicity of conky with a few ideas I have rattling around&amp;#8230; &lt;span&gt;I want:&lt;/span&gt;&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;span&gt;A system monitor that is always visible&lt;/span&gt;&lt;strong&gt; - a wall-mounted display&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;That requires no interaction&lt;strong&gt; - until I need to dig deeper&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;That I can access from anywhere&lt;strong&gt; - on the www&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;That is chunky and obvious from afar&lt;/li&gt;
&lt;li&gt;That is visually appealing&lt;/li&gt;
&lt;li&gt;That shows me everything I need to know&lt;strong&gt; - including business metrics&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;I already have a number of scripts and programs that help me get notified of errors / hiccups / statistics etc but they&amp;#8217;re all so very disparate.&lt;/p&gt;
&lt;p&gt;It is with these things in mind that I am dedicating the next few days to create a basic prototype that doesn&amp;#8217;t suck.&lt;/p&gt;
&lt;p&gt;In a nutshell:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;&amp;#8220;A chunky interface that cycles through core metrics and statistics, slowing down on views with errors.&amp;#8221;&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;There&amp;#8217;s going to be a lot of fun in making:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;span&gt;A &lt;a href="http://getspringy.com/" target="_blank"&gt;force-directed graph&lt;/a&gt; that represents my database&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;A grid of recently processed images&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;Topline database statistics&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;Recent server errors - as chunky as all hell&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;&lt;span&gt;&lt;a href="http://www.soleilnoir.net/believein/" target="_blank"&gt;Inspired by something beautiful&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;span&gt;Wish me luck!&lt;/span&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/44777929341</link><guid>http://oodavid.tumblr.com/post/44777929341</guid><pubDate>Thu, 07 Mar 2013 11:10:31 +0000</pubDate></item><item><title>When you *have* to install all the Internet Explorers, do it in a one-liner</title><description>&lt;p&gt;You know how it is, you make something awesome for a company, they all use modern browsers, but their customers? Oh, they&amp;#8217;re still rocking IE6 and 7. I quite honestly thought those days were long behind us.&lt;/p&gt;
&lt;p&gt;Well, they may seem like dark dark days, but at least we&amp;#8217;re not alone - with the advent and growing popularity of github and general open-sourcery I managed to find this GEM of a repository:&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/xdissent/ievms"&gt;&lt;a href="https://github.com/xdissent/ievms"&gt;https://github.com/xdissent/ievms&lt;/a&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Quite simply, if you have Orcale VirtualBox installed you can download and install all the IE&amp;#8217;s in a command-line onner:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;span&gt;curl -s &lt;a href="https://raw.github.com/xdissent/ievms/master/ievms.sh"&gt;https://raw.github.com/xdissent/ievms/master/ievms.sh&lt;/a&gt; | bash&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Isn&amp;#8217;t it beautiful?&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/42578152347</link><guid>http://oodavid.tumblr.com/post/42578152347</guid><pubDate>Fri, 08 Feb 2013 13:09:00 +0000</pubDate></item><item><title>Inspired by MailChimp: No more social Logins</title><description>&lt;p&gt;We&amp;#8217;d been A-B testing a new &amp;#8220;login with Facebook&amp;#8221; and &amp;#8220;login with Twitter&amp;#8221; links alongside the regular email and password form.&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Group A - Half of our users see the normal register and login with email option&lt;/li&gt;
&lt;li&gt;Group B - This half &lt;strong&gt;also&lt;/strong&gt; see the extra login / registration options&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;We noticed that Group B (those with &lt;strong&gt;three&lt;/strong&gt; login choices) were having increased login failure.&lt;/p&gt;
&lt;p&gt;After a little research we came across an astounding article from MailChimp covering this exact scenario, I&amp;#8217;d be foolish to think I could express this problem nearly as well as these guys, suffice to say that we&amp;#8217;ve came to the same conclusion&amp;#8230; an excellent (if a little lengthy) read:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;blog.mailchimp.com/social-login-buttons-arent-worth-it&lt;/li&gt;
&lt;/ul&gt;</description><link>http://oodavid.tumblr.com/post/36232191240</link><guid>http://oodavid.tumblr.com/post/36232191240</guid><pubDate>Tue, 30 Oct 2012 16:25:48 +0000</pubDate></item><item><title>One awesome personal finances spreadsheet</title><description>&lt;p&gt;Having been involved with a number of &amp;#8220;bootstraps&amp;#8221; &lt;em&gt;(4 in a row!)&lt;/em&gt; I found myself struggling a little with my personal cashflow&amp;#8230; cash&lt;strong&gt;flaw&lt;/strong&gt; might be a more appropriate name TBH.&lt;/p&gt;
&lt;p&gt;So anyhow; last year after a joyous debacle I decided that it was pertinent that I took the bull by the horns and really get to know just how these things work. Today I find myself more than comfortable with finances from the personal level all the way to large-company level &lt;em&gt;(double-entry basics, debit, credit, invoices, credit-notes, credit-ratings, credit-insurers yada yada)&lt;/em&gt; and today I would like to share with you a pretty powerful spreadsheet that I use to analyse my personal bank account.&lt;/p&gt;
&lt;p&gt;&lt;a href="http://oodavid.com/finances/template.ods"&gt;&lt;a href="http://oodavid.com/finances/template.ods"&gt;http://oodavid.com/finances/template.ods&lt;/a&gt;&lt;/a&gt; - designed for &lt;strong&gt;Open Office&lt;/strong&gt;, &lt;em&gt;sorry Excel users, but it probably doesn&amp;#8217;t work! Feel free to port it :-)&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;It&amp;#8217;s been tweaked and tinkered with and I think I&amp;#8217;m finally happy with it. It&amp;#8217;s designed to be a no-brainer to user:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Paste in your bank statement at the end of each month&lt;/li&gt;
&lt;li&gt;Assign each transaction a category&lt;/li&gt;
&lt;li&gt;&lt;em&gt;&lt;strong&gt;Magic happens&lt;/strong&gt;&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;There are 14 tabs:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;About&lt;/strong&gt; - this explains how it works and allows you to set some variables that affect the way the thing works&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Money&lt;/strong&gt; - this is your balance sheet if you will, or a summary of your monthly spendings and earnings with opening balance, closing balance and a grouping of how you spend your cash&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;April &amp;gt; February&lt;/strong&gt; - this is where you paste your bank-statements then categorise each transaction, once you&amp;#8217;ve done that the &lt;strong&gt;Money&lt;/strong&gt; tab is automagically updated!&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;a href="http://oodavid.com/finances/screenshot.png" title="Screenshot"&gt;&lt;img src="http://media.tumblr.com/tumblr_m8hykvcDEW1qk6dpq.png"/&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;by selecting the category the transaction is added to the correct month / category cell on the &lt;strong&gt;Money&lt;/strong&gt; tab (click for a bigger image)&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;So every month I paste in my statement, categorise each item &lt;em&gt;(about 60 on average)&lt;/em&gt; and then I have a number of useful things in my possession:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;An exact breakdown of how much I&amp;#8217;m spending and earning in different areas (groceries, clothes, electronics etc).&lt;/li&gt;
&lt;li&gt;An intimate knowledge of my money. Quite a handy thing when you want to budget etc.&lt;/li&gt;
&lt;li&gt;Proof. Just in-case the taxman or some other arsehole needs it.&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Please download it and have a tinker, if I make your life a teeny tiny bit better just give me some love and we&amp;#8217;re even :-)&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/29059799147</link><guid>http://oodavid.tumblr.com/post/29059799147</guid><pubDate>Thu, 09 Aug 2012 17:57:36 +0100</pubDate></item><item><title>1DayLater is evolving...</title><description>&lt;p&gt;For the past year or so we have been working on building a new 1DayLater from the ground and I&amp;#8217;m letting myself get excited about it; this blog post is clearly premature, but what the hey, I want to write a little about what we&amp;#8217;re doing.&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="http://new.1daylater.com/"&gt;&lt;a href="http://new.1daylater.com/"&gt;http://new.1daylater.com/&lt;/a&gt;&lt;/a&gt;&lt;em&gt; - our holding page, isn&amp;#8217;t it nice?&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m79oy4O9Y11qk6dpq.png"/&gt;&lt;br/&gt;&lt;em&gt;your 1DayLater is evolving&amp;#8230;&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Technology Wise&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The easiest changes to describe are our technologies, almost every choice made in the original system has been reviewed and (mostly) found wanting. We&amp;#8217;ve really matured the software with this new version and myself as a programmer too; I&amp;#8217;m growing ever more comfortable with the iterative development process to the point that I consider a bad day as NOT pushing a new release live.&lt;/p&gt;
&lt;p&gt;A lot of this has come from building the NexGen software with Lucion Environmental &lt;em&gt;(more on this another time)&lt;/em&gt; suffice to say that when you support a diverse and growing company you see the fruits of your labour almost instantly. If the person in the room next door has a bug and they see it fixed instantly there&amp;#8217;s gratitude aplenty!&lt;/p&gt;
&lt;p&gt;I digress, here&amp;#8217;s some of the changes we&amp;#8217;ve made on the new 1DayLater&amp;#8230; and why&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Version Control&lt;/strong&gt;: Subversion &amp;gt; Git&lt;br/&gt;&lt;em&gt;once you get over the initial learning curve, git has many advantages&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Deployment&lt;/strong&gt;: FTP &amp;gt; Git Hooks&lt;br/&gt;&lt;em&gt;we can update the site with simply &amp;#8220;git push&amp;#8221; and all the right files will be in place&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Hosting&lt;/strong&gt;: Rackspace &amp;gt; Amazon Web Services&lt;br/&gt;&lt;em&gt;&lt;em&gt;an excellent developer community and lower price makes this logical&lt;/em&gt;&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Database&lt;/strong&gt;: MyISAM &amp;gt; InnoDB&lt;br/&gt;&lt;em&gt;currently 1DayLater is non-relational, we now require a more logical relational structure&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Markup&lt;/strong&gt;: Handcoded &amp;gt; Twitter Bootstrap&lt;br/&gt;&lt;em&gt;frankly, I can&amp;#8217;t afford to spend too much time pushing pixels - this makes it much quicker to knock up pages&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Templating&lt;/strong&gt;: Custom &amp;gt; Handlebars&lt;br/&gt;&lt;em&gt;I wrote my own templating engine and it was very patchy, we picked the most popular and active engine for the new system&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;PDF Printing&lt;/strong&gt;: wkhtmltopdf &amp;gt; PrinceXML&lt;br/&gt;&lt;em&gt;once we go live we will (gulp) fork out the licence fee for a commercial printing program; after all this will be our new product&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;&lt;strong&gt;Product Wise&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="http://new.1daylater.com/"&gt;&lt;a href="http://new.1daylater.com/"&gt;http://new.1daylater.com/&lt;/a&gt;&lt;/a&gt;&lt;em&gt; - the holding page should explain it nicely, with pictures and all!&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;But if you prefer I can quickly explain what we&amp;#8217;re making:&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;li&gt;Our &lt;strong&gt;Users&lt;/strong&gt; can create &lt;strong&gt;Quotes&lt;/strong&gt; to send to their clients&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Quotes&lt;/strong&gt; are made up of &lt;strong&gt;Line-Items&lt;/strong&gt; with an estimate tally&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Users&lt;/strong&gt; can then &lt;strong&gt;Log their Activity&lt;/strong&gt; against these Line-Items&lt;/li&gt;
&lt;li&gt;They can then convert their Activity into &lt;strong&gt;Invoices &lt;/strong&gt;to send to their clients&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;
&lt;div&gt;For example&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;li&gt;Tony the plasterer Quotes for a small Job&lt;/li&gt;
&lt;li&gt;It is made up of these Line-Items
&lt;ul&gt;&lt;li&gt;3 Days on site at £250 / day&lt;/li&gt;
&lt;li&gt;1 Disposable tarpaulin at £30&lt;em&gt; (estimated)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;1 Day of Van hire at £60&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;On site he logs his work against these activities, on the second day he notices his client has torn the tarpaulin so he gets another one and so logs two of that&lt;/li&gt;
&lt;li&gt;He can then draw up an Invoice&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;The idea is that Tony does the MINIMUM amount of admin but gets access to some &lt;em&gt;&lt;strong&gt;very&lt;/strong&gt;&lt;/em&gt; valuable information and tools, ie:&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;li&gt;Send Invoices and Quotes to his clients&lt;/li&gt;
&lt;li&gt;Get notified when his clients view his Invoices and Quotes&lt;/li&gt;
&lt;li&gt;Find the Quotes with outstanding work (ie money)&lt;/li&gt;
&lt;li&gt;See which Invoices are overdue&lt;/li&gt;
&lt;li&gt;Visualise his profitability&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;
&lt;div&gt;Furthermore he can inviate collaborators to log their activities against his Quotes (maybe he hires staff etc.)&lt;/div&gt;
&lt;div&gt;&lt;strong&gt;&lt;br/&gt;&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;&lt;strong&gt;Business Wise&lt;/strong&gt;&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;Well, we&amp;#8217;ve paid off the business loan, we&amp;#8217;re financially stable (profitable in fact) and are busy investing in the company. On the financial front we&amp;#8217;re pretty happy at the moment but (as all businesses should) we want to be &lt;em&gt;&lt;strong&gt;very&lt;/strong&gt;&lt;/em&gt; profitable and hire more staff for support and whatnot.&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;With the new product we spent a great deal of time pondering how to price the product and catch customers at each stage of the curve, this is what we thought:&lt;/div&gt;
&lt;div&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;When is the product valuable?&lt;/strong&gt;
&lt;ul&gt;&lt;li&gt;When the client sends an Invoice&lt;/li&gt;
&lt;li&gt;&lt;em&gt;we thought that the data, visuals, outstanding work etc were valuable, but that they&amp;#8217;re also so intangible that would be difficult to describe and sell&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;How much is an Invoice worth?&lt;/strong&gt;
&lt;ul&gt;&lt;li&gt;ONE POUND&lt;/li&gt;
&lt;li&gt;&lt;em&gt;We decided that it couldn&amp;#8217;t impact on the value of the invoice but had to be a nice round number, a QUID seems decent. We&amp;#8217;ll review this soon enough&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;How can our users pay for it?&lt;/strong&gt;
&lt;ul&gt;&lt;li&gt;On a subscription (Monthly or Yearly)&lt;/li&gt;
&lt;li&gt;Buy a set number of Invoices (Tokens)&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div&gt;Last time round the finances were second to the product, this time we&amp;#8217;ve actually gone ahead and designed and implemented our payment pages first. Yup, before the product is even finished; we don&amp;#8217;t want bugfixes and whatnot getting in the way of our cashflow, after all if 1DayLater wasn&amp;#8217;t financially viable (for us) those bugfixes and improvements would be worthless as the service would eventually disappear.&lt;/div&gt;
&lt;div&gt;&lt;/div&gt;
&lt;div&gt;Lessons have been learned. I am excited.&lt;/div&gt;</description><link>http://oodavid.tumblr.com/post/27398433575</link><guid>http://oodavid.tumblr.com/post/27398433575</guid><pubDate>Tue, 17 Jul 2012 09:56:15 +0100</pubDate></item><item><title>I'm delighted to announce...</title><description>&lt;p&gt;For the past 8 months I have been working on a contract with one of the country&amp;#8217;s finest Asbestos Surveying companies &lt;a href="http://www.lucion.co.uk/" title="Lucion"&gt;Lucion Environmental&lt;/a&gt;, developing &amp;#8220;NexGen&amp;#8221;; an online platform to service their entire company from quoting to site-work, report generation and finally invoices&amp;#8230; and then some in-between.&lt;/p&gt;
&lt;p&gt;Just last week I managed to &amp;#8220;upgrade&amp;#8221; my contract to the golden-egg of working arrangements - permanent work as a consultant developer! This means that I&amp;#8217;m afforded all the luxuries of self-employment with the added bonus of financial stability for the foreseeable future!&lt;/p&gt;
&lt;p&gt;And now&amp;#8230; some things&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What has made this project different?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;The most exciting thing about working with an established business is that their procedures, company structure and needs are already well defined and instantly available to me. I&amp;#8217;ve not once thought to myself &amp;#8220;this is an interesting feature, I hope it&amp;#8217;s right&amp;#8221; instead I just need to express my ideas to the right person(s) and they tell me straight. In fact I spent most of my first month (or two) doing just this - building a picture in my mind of the company as a single coherent thought; it&amp;#8217;s now so familiar to me that I&amp;#8217;m confidently autonomous in my work. LOVE IT.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;If you&amp;#8217;re a consultant developer, who&amp;#8217;s your boss?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I imagine there are 123 bosses, so in no particular order:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;&lt;strong&gt;120 Staff Members&lt;/strong&gt;&lt;span&gt; - that probably makes me the company bitch&lt;/span&gt;&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Patrick Morton&lt;/strong&gt; - Director, instigator of NexGen&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Me&lt;/strong&gt; - some ideas are too good not to act on, brownie points live here&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The Data&lt;/strong&gt; - if the data says &amp;#8220;help me&amp;#8221;, I oblige&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;I&amp;#8217;ve noticed something interesting with this setup, If you pick out ANYONE from the list and focus solely on making their life easier / happier / better in any way you can, they become more likely to engage with the product - often with so much energy that it infects the people around them. Probably a valuable observation when instigating massive change in such a large company; I bet that&amp;#8217;s how the fashion companies work it: target the alpha males / females and make them happy, then everyone else follows suit.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What&amp;#8217;s next?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Well, we&amp;#8217;ve already seen a gradual rollout in the Northern office, and next week we&amp;#8217;re going live with the remaining 6 regional offices; this entails a meeting of the managers, Directors and myself&amp;#8230; I just &lt;em&gt;know&lt;/em&gt; it will be like when Mafia bosses meet in the movies; all suits, meatballs and gesticulations. It&amp;#8217;ll be awesome.&lt;/p&gt;
&lt;p&gt;After that I have a &amp;#8220;development backlog&amp;#8221; that represents months of solid work; everything from platform engineering, scalability, feature requests, bugfixes and a few things that I&amp;#8217;m confident are going to make the competition weep with envy.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Anything else?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Me and Paul have been &lt;a href="http://new.1daylater.com/" title="New 1DayLater"&gt;rebooting 1DayLater&lt;/a&gt; with a focus on helping freelancers and businesses &lt;em&gt;really&lt;/em&gt; make money and being contractually watertight. Watch this space&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/24410749842</link><guid>http://oodavid.tumblr.com/post/24410749842</guid><pubDate>Mon, 04 Jun 2012 18:39:00 +0100</pubDate></item><item><title>Who's a Git?</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m3tic8wiH81qk6dpq.png"/&gt;&lt;/p&gt;
&lt;p&gt;8 months ago I didn&amp;#8217;t really *do* branching&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m3ticoMYJJ1qk6dpq.png"/&gt;&lt;/p&gt;
&lt;p&gt;today it&amp;#8217;s all I do&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/22786502004</link><guid>http://oodavid.tumblr.com/post/22786502004</guid><pubDate>Thu, 10 May 2012 18:39:55 +0100</pubDate></item><item><title>Linux Screencasting with recordmydesktop</title><description>&lt;p&gt;I have today encountered an item on my todo list &lt;em&gt;(the list is so long I can&amp;#8217;t actually remember writing this item&amp;#8230; madness!)&lt;/em&gt; - which is to record a set of tutorial screencasts for a SaaS that I am developing - quicker than writing help-documents and probably a bit more fun. Something I&amp;#8217;ve been meaning to try my hand at for a long time!&lt;/p&gt;
&lt;p&gt;So there was a little chinstroking and headscratching trying to get this setup to my liking - I encountered some common linux audio problems like static / whitenoise on my mic etc. but in the end the steps to get setup were pretty straightforward; install some apps, set some settings and off we go.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The scenario&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I have:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Ubuntu Linux 12.10 (running XFCE)&lt;/li&gt;
&lt;li&gt;PulseAudio&lt;/li&gt;
&lt;li&gt;A USB Mic that works well with Skype&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;I want to:&lt;/div&gt;
&lt;ul&gt;&lt;li&gt;Record screencasts of my desktop&lt;/li&gt;
&lt;li&gt;Capture my crisp sounding USB Mic&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;strong&gt;Software Choices&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I tried a &lt;strong&gt;lot&lt;/strong&gt; of different programs, some with fancy GUIs, old ones, news ones, VLC had a lookin but in the end these are the programs I like best - they&amp;#8217;re snappy, simple (or no) interface, and they each &amp;#8220;just work&amp;#8221; without extra bloat:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;recordmydesktop&lt;/strong&gt;&lt;em&gt; - command-line screencapturing (very smart)&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;gtk-recordmydesktop&lt;/strong&gt; - a &lt;em&gt;very&lt;/em&gt; simple GUI for the above&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;pavucontrol&lt;/strong&gt;&lt;em&gt; - &amp;#8220;advanced&amp;#8221; pulse audio GUI&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;To install:&lt;/p&gt;
&lt;pre class="brush: bash;"&gt;sudo apt-get install recordmydesktop gtk-recordmydesktop pavucontrol&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Setup&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I will address this part&amp;#8230; WITH A SCREENCAST! &lt;em&gt;How apt.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;iframe frameborder="0" height="315" src="http://www.youtube.com/embed/SvdljjkLB8w" width="560"&gt;&lt;/iframe&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;References&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;While I had to wade through quite a few guides, videos and manpages, these were the only guides I needed in the end:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="https://help.ubuntu.com/community/SkypeTroubleshooting"&gt;&lt;a href="https://help.ubuntu.com/community/SkypeTroubleshooting"&gt;https://help.ubuntu.com/community/SkypeTroubleshooting&lt;/a&gt;&lt;/a&gt;&lt;br/&gt;shows how to select a microphone device with pavucontrol&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.youtube.com/watch?v=sN10CXyOC0E"&gt;&lt;a href="http://www.youtube.com/watch?v=sN10CXyOC0E"&gt;http://www.youtube.com/watch?v=sN10CXyOC0E&lt;/a&gt;&lt;br/&gt;&lt;/a&gt;shows to set your sound device to &amp;#8220;pulse&amp;#8221; on recordmydesktop&lt;/li&gt;
&lt;/ul&gt;</description><link>http://oodavid.tumblr.com/post/22586793328</link><guid>http://oodavid.tumblr.com/post/22586793328</guid><pubDate>Mon, 07 May 2012 15:02:24 +0100</pubDate></item><item><title>Redshift your computer monitor. For the Zzzz...</title><description>&lt;p&gt;I have recently discovered a neat little package for linux called &amp;#8220;Redshift&amp;#8221;; so simple and elegant and very worthy of a mention on the blog.&lt;/p&gt;
&lt;p&gt;&lt;img height="150" src="http://jonls.dk/wp-content/uploads/redshift-icon-256-150x150.png" width="150"/&gt; &lt;/p&gt;
&lt;p&gt;&lt;a href="http://jonls.dk/redshift/"&gt;&lt;a href="http://jonls.dk/redshift/"&gt;http://jonls.dk/redshift/&lt;/a&gt;&lt;/a&gt;&lt;em&gt; - cheers Jon Lund Steffensen!&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Once installed and running at startup, redshift adjusts your monitor(s) colour &amp;#8220;temperature&amp;#8221; to match the time of day / year and local weather conditions. With all these modern gadgets bombarding our eyes it&amp;#8217;s no wonder sleep is &lt;a href="http://articles.cnn.com/2010-05-13/tech/sleep.gadgets.ipad_1_ipad-sleep-disorders-e-book?_s=PM:TECH"&gt;becoming&lt;/a&gt; &lt;a href="http://healthland.time.com/2011/06/27/tv-video-games-at-night-may-cause-sleep-problems-in-kids/"&gt;a&lt;/a&gt; &lt;a href="http://www.webmd.com/sleep-disorders/news/20030620/nighttime-computer-users-may-lose-sleep"&gt;big&lt;/a&gt; &lt;a href="http://imogen-wright.suite101.com/insomnia-linked-to-pc-use-a237276"&gt;problem&lt;/a&gt;; this wee helper acts as a great cue that it&amp;#8217;s time to shutdown and get some shuteye.&lt;/p&gt;
&lt;p&gt;And on that note&amp;#8230; Zzzz&amp;#8230;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/21527379040</link><guid>http://oodavid.tumblr.com/post/21527379040</guid><pubDate>Sat, 21 Apr 2012 23:20:21 +0100</pubDate><category>linux</category></item><item><title>Automatically backup MySQL to Amazon S3 (and a dog)</title><description>&lt;p&gt;I&amp;#8217;ve been revisiting my backup scripts today and I decided to publish my notes on how to backup your MySQL databases to Amazon S3 - I forgot just how simple it was:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Install s3cmd&lt;/li&gt;
&lt;li&gt;Write a bash script that&amp;#8230;
&lt;ul&gt;&lt;li&gt;lists your databases&lt;/li&gt;
&lt;li&gt;dumps them to a temporary file&lt;/li&gt;
&lt;li&gt;uploads them to s3&lt;/li&gt;
&lt;li&gt;deletes the temporary file&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;li&gt;Run it with cron every night&lt;/li&gt;
&lt;/ul&gt;&lt;div&gt;The full instructions are here:&lt;/div&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="https://gist.github.com/2206527"&gt;&lt;a href="https://gist.github.com/2206527"&gt;https://gist.github.com/2206527&lt;/a&gt;&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;(and a dog)&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m1i5hmW6Qu1qk6dpq.jpg"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;I&amp;#8217;m gonna meet this pup at &lt;a href="http://www.nessr.net/node/73" title="North East Springer Spaniel Rescue"&gt;the NESSR Easter Event&lt;/a&gt; next weekend&lt;/em&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/19958949423</link><guid>http://oodavid.tumblr.com/post/19958949423</guid><pubDate>Mon, 26 Mar 2012 18:22:42 +0100</pubDate></item><item><title>Refactoring an old database for multilang support</title><description>&lt;p&gt;I&amp;#8217;ve recently had the opportunity to revisit and re-factor a database that I wrote designed a decade ago; it&amp;#8217;s still up-and-running with heavy traffic however it&amp;#8217;s become difficult for the current developer to maintain &lt;em&gt;(hey Dad)&lt;/em&gt; and the client is looking to add a multi-language slant.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m0vio9duHD1qk6dpq.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;the old, non-relational database&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m0vio12Oju1qk6dpq.png"/&gt;&lt;br/&gt;&lt;em&gt;the new relational database + multilang translations&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;Table-wise we decided to keep with pretty much the same to make the transition painless, however when you compare the original and the new you can see everything has more structure and logic:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Converted from MyISAM to InnoDB&lt;br/&gt;&lt;em&gt;the new MySQL standard&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Foreign-Keys have been added&lt;/li&gt;
&lt;li&gt;Additional Unique indexes for structural integrity&lt;/li&gt;
&lt;li&gt;Split the content into
&lt;ul&gt;&lt;li&gt;Structural tables&lt;/li&gt;
&lt;li&gt;Content tables (for multi-lang)&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m0vke31FY41qk6dpq.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;structure on the top, content on the bottom&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;With this structure we can do some pretty nifty queries that pull out the language of choice but fall-back to English on a &lt;strong&gt;per-column-basis&lt;/strong&gt;, observe:&lt;/p&gt;
&lt;pre class="brush: sql;"&gt;SELECT
	u.id,
	COALESCE(lang1.title,     lang2.title)      AS title,
	COALESCE(lang1.body,      lang2.body)       AS body,
	COALESCE(lang1.voiceover, lang2.voiceover)  AS voiceover,
	COALESCE(lang1.handout,   lang2.handout)    AS handout
FROM `units` AS u
	LEFT JOIN units_lang AS lang1 ON lang1.unit = u.id AND lang1.lang = 'zh'
	LEFT JOIN units_lang AS lang2 ON lang2.unit = u.id AND lang2.lang = 'en'
WHERE u.id = 32;&lt;/pre&gt;
&lt;p&gt;&lt;br/&gt;In this statement:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;strong&gt;u&lt;/strong&gt; is the structural &lt;strong&gt;units&lt;/strong&gt; table with common info (only id in this case)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;lang1&lt;/strong&gt; is the multilang table &lt;strong&gt;units_lang&lt;/strong&gt; in Chinese (zh)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;lang2&lt;/strong&gt; is the multilang table &lt;strong&gt;units_lang&lt;/strong&gt; in English (en)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;COALESCE&lt;/strong&gt;picks out the first NON-NULL column, so these go:
&lt;ul&gt;&lt;li&gt;Chinese table&lt;br/&gt;&lt;em&gt;then&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;English table&lt;/li&gt;
&lt;/ul&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Pretty nifty huh?&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/19288335196</link><guid>http://oodavid.tumblr.com/post/19288335196</guid><pubDate>Wed, 14 Mar 2012 13:08:00 +0000</pubDate></item><item><title>A nice search solution and interface :-)</title><description>&lt;p&gt;&lt;em&gt;You&amp;#8217;ll probably get lost in this post. I should doodle a diagram&amp;#8230; Apologies.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;So today I&amp;#8217;ve tasked myself with improving the search feature on the NexGen project (itself a post for another day), the scenario is this:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;A Company has Contracts&lt;/li&gt;
&lt;li&gt;Contracts are linked to Accounts and Primary Contacts&lt;/li&gt;
&lt;li&gt;Contracts are made up of Jobs&lt;br/&gt;&lt;em&gt;There may be hundreds or thousands of Jobs in the case of rolling contracts&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;Jobs are linked to Sites and various other bits and bobs&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;The search should allow you to get you from the homepage to the exact piece of information you need based on the information at hand - you might have a Site Address, Client Name, Reference ID etc.&lt;/p&gt;
&lt;p&gt;The search itself is fully functional, however I&amp;#8217;ve not been 100% happy with the interface - &lt;em&gt;until today!&lt;/em&gt; The old interface was pretty bog standard:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Show a list of results that match the search criteria&lt;/li&gt;
&lt;li&gt;Don&amp;#8217;t show results that don&amp;#8217;t match the search criteria&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Pretty simple right? Indeed, but the interface actually requires MORE components:&lt;/p&gt;
&lt;p&gt;Lets say we searched for the Site: &amp;#8220;Durham Castle&amp;#8221; - it&amp;#8217;s used by 2 Jobs within a single Contract. That Contract has other Jobs at different sites. If we only show those two Jobs then how do we see the other Jobs? We need:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;A show-all Jobs button&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Not so bad right? Well, I think it is awful - the interface bit is OK, the coding bit is OK, but the users of the system have to be aware that &amp;#8220;we&amp;#8217;re only showing the Jobs that match your search&amp;#8221; - it might not be obvious that there&amp;#8217;s other Jobs in that Contract!!&lt;/p&gt;
&lt;p&gt;So my solution is to show all the Jobs (well, paginated) but with the search results at the top. In the prime spot :-)&lt;/p&gt;
&lt;pre class="brush: sql;"&gt;SELECT * FROM `jobs` ORDER BY site=22 DESC, id ASC;&lt;/pre&gt;
&lt;p&gt;I&amp;#8217;m really happy with this one even if you don&amp;#8217;t get it.&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/17708985844</link><guid>http://oodavid.tumblr.com/post/17708985844</guid><pubDate>Thu, 16 Feb 2012 12:53:16 +0000</pubDate></item><item><title>Deploying with Git(HUB)</title><description>&lt;p&gt;The last post about deployment was good, but I ran into a few problems to do with submodules. I am developing 3 web-apps in parallel that all use common code, so in keeping with DRY methodology the apps simply link to submodules in order to share code. With the technique outlined in the previous post submodules were not automatically updated; making it all but useless for my needs.&lt;/p&gt;
&lt;p&gt;So today I have quickly researched and utilised an alternative - using github features to trigger automatic deployment.&lt;/p&gt;
&lt;p&gt;In keeping with trendy trends, here&amp;#8217;s the &lt;a href="https://gist.github.com/1809044" title="Auto-deploy with php and git(hub) on an EC2 Amazon AMI"&gt;GIST on GitHub&lt;/a&gt; - you can see that I have forked a very good gist and there&amp;#8217;s a few references in the post.&lt;/p&gt;
&lt;p&gt;I have a pretty nice announcement with-regard-to my worklife to make soon, but need to wait till everything is confirmed before I do. Happy times my friends :-)&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/17492884853</link><guid>http://oodavid.tumblr.com/post/17492884853</guid><pubDate>Sun, 12 Feb 2012 16:42:44 +0000</pubDate><category>nerd</category></item><item><title>Deploying with Git &gt; handy hints</title><description>&lt;p&gt;With regards to deploying your site with git, there&amp;#8217;s some potentially confusing posts out there; a quick google for &amp;#8220;git deployment&amp;#8221; will turn up a few (seemingly) outdated posts (I&amp;#8217;m using &lt;strong&gt;git version 1.7.4.1&lt;/strong&gt; at the time of writing), ie:&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;&lt;a href="http://ryanflorence.com/simple-git-deployment/"&gt;&lt;a href="http://ryanflorence.com/simple-git-deployment/"&gt;http://ryanflorence.com/simple-git-deployment/&lt;/a&gt;&lt;br/&gt;&lt;/a&gt;&lt;em&gt;I had a few problems with this one when I got to the push stage, apparently this occurs with newer versions of git.&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://blog.zerosum.org/2010/11/01/pure-git-deploy-workflow.html"&gt;&lt;a href="http://blog.zerosum.org/2010/11/01/pure-git-deploy-workflow.html"&gt;http://blog.zerosum.org/2010/11/01/pure-git-deploy-workflow.html&lt;/a&gt;&lt;/a&gt;&lt;br/&gt;&lt;em&gt;while written for specific deployment platforms I ran into the same problems as the ryanfolrence post&lt;/em&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://toroid.org/ams/git-website-howto"&gt;&lt;a href="http://toroid.org/ams/git-website-howto"&gt;http://toroid.org/ams/git-website-howto&lt;/a&gt;&lt;/a&gt;&lt;br/&gt;&lt;em&gt;now we&amp;#8217;re talking! Not only is this kept up-to-date but works a treat :-)&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;If you take a peek at the &lt;strong&gt;toroid&lt;/strong&gt; post you&amp;#8217;ll read:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;The one-line summary: push into a remote repository that has a detached work tree, and a post-receive hook that runs &amp;#8220;git checkout -f&amp;#8221;.&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Which I now understand to mean:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;When you push to a remote repo a script will run that updates another directory (that&amp;#8217;s the &amp;#8220;detached work tree&amp;#8221; bit)&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Perfect! I&amp;#8217;ve already got my servers up and running so I don&amp;#8217;t want to start moving directories about the place, so for me this is what I did to pretty seamlessly add git deployments&lt;/p&gt;
&lt;ul&gt;&lt;li&gt;Create a git repo in &lt;strong&gt;/var/www/html.git/&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Have that repo update my working directory &lt;strong&gt;/var/www/html/&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;em&gt;err&amp;#8230; that&amp;#8217;s it!&lt;/em&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;SSH into the remote machine&amp;#8230;&lt;/p&gt;
&lt;pre class="brush: bash;"&gt;# Move to the /var/www/ folder
cd /var/www/
# Make a new folder for our bare git repo
mkdir html.git
cd html.git
# Intialise a bare git repo
git init --bare
# Create our post-receive hook file (this simply writes 2 lines to the file)
echo -ne '#!/bin/sh\nGIT_WORK_TREE=/var/www/html git checkout -f' &amp;gt; hooks/post-receive
# Make our post-receive file executable
chmod +x hooks/post-receive&lt;/pre&gt;
&lt;p&gt;On your local machine you can now push to the remote repository and your working directory will be updated:&lt;/p&gt;
&lt;pre class="brush: bash;"&gt;# Add the remote repo
git remote add www ssh://username@IPorURL/var/www/html.git
# Now push
git push www master&lt;/pre&gt;
&lt;p&gt;And you&amp;#8217;re done. That was simple!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Quick word of warning&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;My local repo also runs on a local server, for me I must be careful of my /uploads/ folder as scripts can write to that directory, I don&amp;#8217;t want those files tracked by git so I use a .gitignore file to make sure that no hiccups occur in that department :-)&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/16765723032</link><guid>http://oodavid.tumblr.com/post/16765723032</guid><pubDate>Mon, 30 Jan 2012 17:21:01 +0000</pubDate></item><item><title>The best programmers CV I could think of</title><description>&lt;p&gt;The curse of the creative type: &lt;em&gt;&amp;#8220;my blog needs a new skin&amp;#8221;&lt;/em&gt; or &lt;em&gt;&amp;#8220;my business cards aren&amp;#8217;t moo enough&amp;#8221;&lt;/em&gt; or in my case &lt;em&gt;&amp;#8220;my CV is no longer appropriate&amp;#8221;&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;You&amp;#8217;ve guessed it, I&amp;#8217;m looking for full-time employment. Not freelance contracts, more projects or exciting startups (they&amp;#8217;re good and all) but I&amp;#8217;ve become keen to learn from a the kind of peergroup available in a large company. I think this has grown from conversations with a few peers who have made the transition from freelance / startup to corporation.&lt;/p&gt;
&lt;p&gt;So without further ado, my CV: (click to view big)&lt;/p&gt;
&lt;p&gt;&lt;a href="http://oodavid.com/cv.htm" title="My CV on oodavid.com"&gt;&lt;img src="http://media.tumblr.com/tumblr_lyf8p4IGmd1qk6dpq.png"/&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;em&gt;The words are my own, but the colour scheme was unashamedly taken from &lt;a href="http://www.sublimetext.com/" title="Sublime Text"&gt;Sublime Text&lt;/a&gt;; I wrote a simple syntax highlighter to make it so :-)&lt;/em&gt;&lt;/p&gt;</description><link>http://oodavid.tumblr.com/post/16534374476</link><guid>http://oodavid.tumblr.com/post/16534374476</guid><pubDate>Thu, 26 Jan 2012 20:20:34 +0000</pubDate></item></channel></rss>
