July 2008 - Posts
I came across an interesting post on Green Blog yesterday which postulated that the reason why most people don't care about the environment is because they don't care about themselves. It went on to suggest that they also don't take responsibility for making themselves happy, continuing in dead-end jobs and not pursuing their dreams, and that how they treat the planet is a mirror for how they treat themselves.
This post really resonated with me, particularly as I'd just finished reading an article in the current issue of Permaculture magazine which advanced similar sentiments, arguing that most people stick with jobs that don't suit them whilst their real passions have become hobbies that they do in their spare time. The article went on to suggest that if more people gave up the dead end jobs and concentrated on pursuing their passions this would drastically increase their 'contribution footprint', benefiting society and helping it address some of the current challenges, including the environmental ones. It doesn't matter what their passion and contribution is, the fact that they are passionate about it and motivated to pursue it can only help to move society forward.
Now this might all sound like new-age clap-trap but it does resonate with a number of the issues I've been pondering over the last few years. The reason I started Codefounders was precisely to enable my to follow my passion - I love writing software - to help escape a job that was no longer fulfilling me and, to a large extent, sapping my will to experience life to the full. I'm still not quite there yet and modesty prevents me claiming that my efforts have made society one iota better, but for some reason I find these two articles really appealing. I'm heading off on vacation soon so maybe a couple of weeks of relaxation will help me sort out some of my future plans and help me plot a more fulfilling future that enables me to follow my passions more.
del.ico.us |
Digg It |
Technorati |
StumbleUpon |
Furl |
reddit
For many years now software companies have been engaged in the practice of dogfooding, actively using their own products to convey their confidence in them. I was interested to read yesterday that the UK Government is dogfooding its own IT carbon reduction strategies and aiming to become the first government in the world to make its computer systems carbon neutral (Whitehall bid to cut IT emissions). This is indeed a laudable aim, though at this point in time it applies only to the Department for the Environment, Food and Rural Affairs (DEFRA) and not the whole of the government but it is an excellent move in the right direction.
Apparently the move to a carbon neutral computing resource is to be achieved through a combination of offsetting, switching off unused computers and ensuring that servers don't remain idle overnight. According to the sources, UK government computer systems account for a whopping 20% of the total government carbon emissions which is probably a far greater proportion than for most other computing users. Turning off idle computers has a significant role to play in this strategy and it is reckoned that this will save 117,500 tonnes of CO2 each year, equivalent to removing 40,000 cars from the road. Not only is this good for the environment it should also be good for the taxpayer as there will be a similar significant reduction in the government's energy bill.
DEFRA haven't approached us with regard to using our Powerdown energy saving software as part of this strategy. My understanding is that they have invested heavily in new networking hardware to allow them to run a Wake-On-LAN based solution offered by one of our competitors. We think that Powerdown is a much more reliable and cost effective solution as it does not rely on Wake-On-LAN, which can be notoriously flaky, and will even work when computers are disconnected from the network. If the government are interested in using Powerdown we would be more than happy to talk to them.
And yes, Codefounders does eat its own dogfood too. We run the latest production and development builds of Powerdown on all of our client computers, both at home and in the office. We also recently published an article describing some measurements that were taken in the field on a customer's system to show how effective Powerdown can be in saving energy and reducing carbon emissions. Check out the article on our site for the full results and details of how we conducted the measurements.
del.ico.us |
Digg It |
Technorati |
StumbleUpon |
Furl |
reddit
I've spent most of my day today trying to copy some files from one location to another using MSBuild. This is something I've done plenty of times before, but in this case I was trying to do something other than just copy an entire directory of files. I'll be the first to admit to being a bit thick sometimes, but MSBuild really does confuse me sometimes and I guess today was one of those times. MSBuild is certainly powerful but I find some of the operations a little counter-intuitive; I think it has something to do with my (mis)understanding of when/how some of the expression in the build file get evaluated.
The problem I was trying to address in this case was to delete all the files and subdirectories from the destination directory except for a specific subset of files/directories, and then copy a subset of files from the source directory to the destination directory. The image below, which shows the directory hierarchy in the destination directory, illustrates the scenario better
I needed to delete all the files in all the directories and subdirectories of the destination except for the files in the B2 directory. I then needed to delete all the subdirectories of the destination except for B and B2.
Whilst this is easy to accomplish with a few lines of C#, it is substantially more tricky with MSBuild and I couldn't make it work with a single list of files. One of the quirks of MSBuild is that to create a list of directories you have to start with a list of files and extract the directory metadata from each list item to create the list of directories, but if a directory has more than one file then it will appear in the directory list multiple times. If you set the <RemoveDir> task to fail on errors then it will cause the build to stop whenever it tries to remove a directory that it has already removed, which is always the case if the directory appears in the list more than once. Setting the task to continue on error seems like a bit of a nasty hack. Surely there must be a better way to define a set of directories which eliminates duplicates, but if there is I don't know what it is.
Anyway, back to the plot... Obtaining a list of all the files except those in the B2 directory is easily achieved by creating an item group and judiciously using the Exclude attribute to ignore the files in B2. But I also need a list of directories which have to be deleted. Using the file list metadata to create the directory list doesn't work because the directory B always appears in the list and the behaviour of <RemoveDir> is to recursively remove all directories. This causes B, B2 and the files I'm trying to preserve to be removed from the destination. Definitely not the outcome I was looking for. I haven't managed to solve the problem fully yet but I have a solution which works well enough for now. What I really need is a custom MSBuild task which does not delete directories recursively; why on earth did the MSBuild team not add that as a conditional switch?!
In total I reckon I've spent about 6 hours trying to MSBuild to copy my files and I wish it didn't have to be so hard. There was one bright point to the day though when I found that Partho P Das has created a freely available MSBuild Visual Debugger tool which is available on CodePlex. Admittedly it's not quite as fully featured as Visual Studio and is obviously a work in progress but it's a great little tool which lets you set breakpoints in MSBuild files and inspect properties, items and the call stack. My productivity in trying to solve this problem went up dramatically once I found Partho's tool. It's much quicker running and debugging a build file through his tool than it is through Visual Studio. If you find yourself working on MSBuild files then I wholeheartedly recommend you get hold of a copy of it as it will make your life significantly easier.
del.ico.us |
Digg It |
Technorati |
StumbleUpon |
Furl |
reddit
Modern business, at least in the Western economies, is predicated on continued economic growth and returns for shareholders which often results in the the ability to generate profits being viewed as the only indicator of success. I may be odd, but I've never really subscribed to this point of view. Aside from the fact that I don't see how you can have infinite growth in a system bounded by a finite availability of resources, I think there are many more ways in which businesses can be perceived to be successful and valuable contributors to society and the lives of their employees.
I started musing on these ideas again today when I met with the owner of a successful local business. He was justifiably proud that he had grown the business from nothing to a £130 million+ annual turnover in under two decades, and we got talking about various issues. He recounted a story to me from his own business experience. He had been visiting a customer with a junior member of his sales team to attempt to close a deal with a potential customer. The customer wanted some bespoke work undertaken and, on the way to the meeting, the business owner and salesman had discussed how much it would realistically cost to undertake the work. They estimated £4,000 to £5,000.
One of the business owner's rules is never to answer the 'how much will it cost' question which most customers are naturally keen on asking, preferring to charge as much as he can reasonably get away with. So he was taken aback in the meeting when, asked how much the work would cost, the salesman replied 'Oh, £4,000 to £5,000'. Fortunately (from the business owner's viewpoint) the customer misheard the salesman and replied '£45,000? Oh we had budgeted £50,000 so that's ok'. The salesman quickly recovered his slip and commented that they would try to do the work for less than £45,000 if at all possible. A couple of days after the meeting the salesman contacted the company with an estimate for £38,000 and indicated that they were undertaking the work at an attractively low rate in the hope that further work might follow. The customer accepted the estimate, delighted to be getting the work done at what he perceived to be an attractive price and below his budget of £50,000. He was subsequently pleased with the work that was performed and placed another two orders at £38,000 each.
So what's wrong with this scenario? Nothing, apart from the fact that the business owner exploited the customer's misperception, lied about the attractive rate he was giving, charged 8 times over the odds and further compounded the error by doing it all over again on two further occasions. This business owner behaved no differently than 99% of businessmen whose yardstick of success is their profits and he acted in the best interest of maximising his performance against his success metric. In all other respects he is a decent, fair-minded human being but I believe this kind of business behaviour to be fundamentally unethical.
I have always tried to operate Codefounders as an ethical, fair minded business which acts with its customers best interests at heart and our aim has never been to generate maximum profits and returns for our shareholders. Had I been the business owner in the scenario above I would have corrected the customers mishearing and quoted the real price we expected to charge for the work. Taking the bigger picture, we have no idea of how the customer would have used the money saved if he had been charged the 'correct' price; it may just have helped boost his own profits or he may have used it to reward his staff in some way for all their hard work during the year. He may have used it to sponsor the local football team or help buy the play equipment which the local school could not otherwise afford.
To my mind the business which gives back to the community is significantly more successful than one which makes its shareholders a little bit richer (and yes, I know that all our pension schemes make their money from shareholdings in other companies, but that is a topic for some other time). Under UK law I believe that companies have a duty to maximise their returns to shareholders. I own 80+% of Codefounders and as the majority shareholder my direction for the company has always been to treat our customers fairly, make sufficient money to cover our costs, pay our staff a wage that affords them a comfortable standard of living and provide an enjoyable and motivational working environment. Hopefully that is your experience of our company if ever you do business with us. If we make excess income then I see no better way to use it than for the benefit of the wider community in which we operate.
The profit-focused mindset of Western businesses is very much an 'I'm alright Jack' mentality. The world faces a huge range of environmental and social challenges in the coming decades and the solutions to these will require much more collaborative and cooperative behaviours. Perhaps if businesses take the lead and focus less on their own financial success metrics and consider themselves successful if they make a positive contribution to society in others way we will beginning to move towards a community that can respond to those challenges.
del.ico.us |
Digg It |
Technorati |
StumbleUpon |
Furl |
reddit