Archive for October, 2007

Gentoo linux and fluxbox

Friday, October 19th, 2007

By nature i like to try stuff out and have a bit of a tinker so with an old dell inspiron 4150 we had in the house I decided to spend a day messing about with linux.

Now as you may know laptops are usually what some people might call “a bit of a bastard” when it comes to installing anything other than windows. Now I haven’t seriously used a Linux distro in about 3 years so I decided to check out one that I had heard a lot about recently; Ubuntu as it turned out this was a bit of a mistake the inital startup gladly informed me it was having trouble reading my floppy drive before dying horribly, not surprising really considering I don’t have one. Googling around for a bit revealed this was a known issue with my laptop the other being having the parallel port enabled in BIOS broke the sound card (WTF) with a lot of people not making much progress I decided to turn back to a distro I was familiar with Gentoo.

Gentoo’s inital kernel fired up ok and then came the fun bit; the install. Now Gentoo basically likes to compile everything and give you a load of options about how you set your system up, this is great if you have an old system and you want to install the minimum of stuff so it runs as fast as possible. The downside is it takes forever. Its not for the weak of heart but by the end you feel like you have achieved something and quite possibly learned something too. The main install guide ends with getting your system configured to your preference and fully bootable what it doesn’t do is tell you how to setup X, I really like this because as window managers go i love the little known fluxbox. Fluxbox is quite simple, lightweight and looks good too, its a brilliant window manager I used extensively during my uni days for development. Luckily someone that uses it likes it as much as i do and created a helpful guide for Gentoo users. Flux is .

Now theres quite a difference between setting up for fun and actually using it full time. Yesterday my main PC died the culprit; broken memory, result? one scrambled windows PC. With the postman a few days away I’m back on the laptop so I decide my desktop needs prittying up a bit this is where i hit a problem:


fbsetbg -f mybackground.jpg

produced something along the lines of:


Esetroot: unable to load image file

Helpful it wasn’t I found out that another program called feh could also be used to a background trying to find out if it was a general problem setting background feh firmly pointed the finger at imlib2. Emerging this imlib2 didn’t have any effect until I realised why apparently you need to do this:


USE="jpeg gif" emerge imlib2 --newuse

Now for people that don’t know how emerge works what its basiclay saying is install imlib2 with support for jpeg and gif files, now why it doesn’t do this as a matter of course ill never know and generally such questions are best left unanswered when it comes to Linux as usually there long and boring. In the end things turned out fairly nice:

fluxbox desktop

Adventures With Analytics

Sunday, October 7th, 2007

Now if your the kind of person I am you will love stats. I don’t even think its a geek thing, some people just don’t seem to be able to resist the lure of the how many and when, from programing to football to government reports you cant escape them so why should my site be any different?

Pretty much everyone has heard of google analytics by now but I wounder how many people really know what it can do and have seen it in action and how many people actually use it to its full potential? Untill a couple of days ago I knew neither what it could do or used it to its full potential now I’m doing both and the ammount of detailed statistics it can show is amazing maybe a little scary. Most people will just use the bit of code it gives you when you first get an analytics account this will give you some info but not everything to get the full benifit you need to do stuff with onclicks to monitor outbound links downloads etc. Now thats a lot of work you may think (unles you do some horibly slow client side dom traversal) well it is if you’ve already got an existing site but then I got thinking - “wordpress? somone must have done it” and they had.

Enter Joost de Valk a SEO loving guy from the Netherlands. I had a look at a few plugins but his was the best you can get an awfull lot of data on outgoing links and downloads using this and it has the ablity to do some other stuff aswell he was also kind enough to give some help and decent default settings to get you going straight away.

All this got me thinking about the data that could possibly be collected on a e-commerce site and which no doubt is collected by the major players and the value that data must have to them. Now with using analytics I can see the potential it has in the smaller market and how a smaller nieche store might really benifit from it and the potential extra value it might add to any such site…

Real Cider

Wednesday, October 3rd, 2007

Anyone who knows me will know how much I enjoy a glass of nice cider, they may have even heard me rave on about a particular cider works; biddenden’s. Now rewind a few years to when I first discovered real cider I was at the beer festival in Newcastle a lively even run by the Newcastle arm of CAMRA not being a big real ale drinker I decided to try some of the ciders, that moment changed my view of ciders. When people say cider you usually get this image of kids in a park drinking 2 liters of what might charitably be called piss, the real cider I tasted that day was like biting into the best tasting apple you have ever eaten.

Anyway fast forward a few years and now luckily for me the range of ciders you can get is expanding in decent pubs you now have a choice of more than strongbow and woodpecker but wait it gets better! Now the cider works themselves are starting to sell direct and that brings me back to biddenden’s. I first discovered there cider while in Kent we visited the vineyard/ciderworks and bought a couple of bottles which I then consumed far too quickly luckly on the back of one of the bottles I spotted a domain name, the rest is history. For about £40 you can get 12 litres of the good stuff shipped to your door, this Christmas I’m thinking about getting a case of spiced cider known as ‘Monks Delight’ (lovely warm) to pass those cold evenings :)

Free Ruby on Rails Ebook

Tuesday, October 2nd, 2007

The people at sitepoint are giving away one of their books, check it out at http://rails.sitepoint.com its free for the next 60 days so get it while you can…

A Change Of Heart

Monday, October 1st, 2007

It was in some respects a long time coming like a lot of people out there I have made the move to word-press and for once actually managed to create a semi-decent (I think) looking theme. I liked Mephisto but I couldn’t do ‘things’ with it. It kind of leads me into what I have been having quite some thought about latley and that is PHP.

I ve had somewhat of a resurgence in my love for PHP, Ive been toying with RoR and done some C# stuff recently at work and I came to miss the pure dirtiness of PHP. The reason I originally had started to hate PHP can probably be pinned on two things; doing maintenance on existing projects and as a result writing increasingly hacky and horrible code. The change of heart came from realising finally that I could write beautiful OO PHP5 that was incredibly rewarding to write if I wanted to. The epiphany was mostly down to the fact that programing in a language like C# made me give up a lot of my bad programing habits. Its quite easy to write bad C# apps but it quickly becomes quite self evident how horrendous it is, while doing something equally bad in PHP like mixing up function with formatting isn’t so obvious until much later when problems start cropping up. By bringing these good habits from C# and RoR to PHP5 I can write much more reliable and readable code thats also fairly agile. This article by Derek Sivers kinda sums things up.