Monday, 30 July 2007

My coding silver anniversary


29th July 1982. A great time to be alive in the UK. We may have lost appalling in the World Cup but at least we'd beaten the Argies in a game of soldiers. But more importantly after about two months of waiting I finally received my first computer - the venerable ZX81



In short order (a few hours - I had to work out how to type first!) I had my first program written

10 PRINT "HELLO"
20 GOTO 10
Shortly after that I ran out of memory... after all the thing only had 1KB :-)

Yes, I've now been writing code for 25 years - a full quarter of a century.

Time to do something special to celebrate.

Sunday, 29 July 2007

A taxing time for couples

When I was legal director of PCG (Professional Contractors Group) back in the early days of the new millennium, a strange case crossed my desk. Apparently somebody in the Inland Revenue was trying to apply the settlements legislation to a couple of contractors, which meant that the higher earner would pay tax at over 45% on the lower earner's share of the business.

I didn't spend much time on it because I was tied up with the judicial review against IR35, and I figured it would be sorted quite quickly once PCG's investigation team got involved. As every contractor knew at the time - a company run by a married couple is probably a settlement, but there is an 'outright gift' exception for married couples. That then puts them on a par with unmarried couples and normal partnerships.

After some seven years the House of Lords finally agreed with the contractors. And then as soon as they won, the government decides it is going to change the law to stop what it calls 'income splitting'. Why they couldn't have done that in the first place rather than leading everybody a merry dance for seven years is something people ought to ponder the next time they are asked to put an X on a piece of paper.

That the government is going to introduce one of their wonderfully effective 'targeted' pieces of legislation is not new of course. Taxation experts and lawyers are already rubbing their hands with glee at the extra fees this thing will generate. What worries me is that the government is conveniently avoiding a couple of other issues.

If 'income splitting' is wrong and individuals should be taxed according to their contribution, then why is income based upon physical assets to be taxed differently.

For example if a couple have a Buy-to-Let business then income (and capital gain!) from that business can be split 50/50 and nobody seems to get upset - regardless of where the money came from to purchase the houses and regardless of the effort put into running the business.

Similarly if an individual pays into a spouse's ISA or a pension, or simply puts assets in the name of their spouse then the income from those assets is taxed as the spouse's income.

Why is income from physical assets so different from that from intellectual assets? It makes no sense.

And of course if you introduce the notion of 'income splitting' so that the exchequer can transfer money to the highest taxed individual on a whim, then surely it is only 'fair' (to use that appalling PR phrase the government is so fond of) to consider the opposite issue of 'income aggregation'.

Is it 'fair' that when an individual sacrifices their earning potential so that their spouse can earn a higher wage, that the spouse is taxed on *all* the income generated? Often at a punitive marginal rate of up to 45%.

Isn't it about time that unpaid carers and housekeepers and personal assistants received a wage for their efforts, and were taxed accordingly?

If 'income splitting' isn't fair, then 'income aggregation' is an outright scandal.

Wednesday, 25 July 2007

Vim Rails in Gutsy!


I use Ubuntu as my development desktop and vim as my editor. It has always surprised me that there are loads of blog posts around the Internet describing how to download various things, but nobody has bothered to package them up and get them into the actual distribution.

So following the 'scratch your own itch' principle, I've packaged up a bunch of vim-scripts that help me when editing Rails applications. These have been accepted into Ubuntu and are available in the forthcoming Gutsy distribution, where you will be able to do:
sudo apt-get install vim-rails

to install the software, and then
vim-rails-setup

to make the necessary changes to your vim configuration.

If you want to install the package on feisty, you'll need to hook into the 3Accounts apt repository. (Or better still volunteer to do the backport to feisty-backports).

Download the shell script at
http://rubyforge.org/frs/download.php/22894/3accounts-apt-setup
save it somewhere and run it with
sudo sh ./3accounts-apt-setup

After a swift:
sudo apt-get update

you're ready to install vim-rails.

Obviously this is just my package of scripts. If you find a problem with it, or think there is another script that makes Rails editing even better then post a comment, or file a bug using Launchpad.

Wednesday, 18 July 2007

The Rails Toolkit


In my never ceasing quest to simplify things, I've decided to automate the 'getting ready to develop in Rails' routine. There are dozens of blog entries showing how to set up your Rails development environment, all of which seem to involve a long list of instructions and a good deal of compiling. But few, if any have wrapped that up in a script, and even fewer have bothered to package the instructions using the distribution's package manager.

So I thought it is time all that changed. I've put together a couple of installation packages for Ubuntu, and a dependency Gem that distill the entire setup process down to:
sudo apt-get install rails-toolkit && sudo gemcmd install rails-toolkit -y
Or at least it will do, once I succeed in getting the packages into the Gutsy distribution.

Until then if you want to help me test the package, you'll need to hook into the 3Accounts apt repository. Download the shell script at
http://rubyforge.org/frs/download.php/22894/3accounts-apt-setup
save it somewhere and run it with
sudo sh ./3accounts-apt-setup
Once the repository is in place you can run
sudo apt-get install rails-toolkit && sudo gemcmd install rails-toolkit -y
and watch your Rails development environment install automatically.

Note that the packages in the repository are targetted at Feisty. You need to be running that version.