Skip to main content
 

Carbon 0.2.3 Released

I've released another version of Carbon, the framework powering this website. It's really a refinement and bugfix release, with the following changes:

  • config: Admin password now needs to be manually enabled
  • cache: Correctly generate htaccess
  • deployment: only replace hostnames in text files
  • cache: only write cache when caching is enabled.
  • theme: remove older articles link (non functional)
  • deployment: new feature - replace hostname from a to b before deploying cached site

Releases are available via github by clicking on tags.

Screencast

To celebrate the new release, I've also recorded another screencast (list of screencasts). In Screencast #4, we create a new post using the admin interface; use the generate site feature to create a full static cache; and finally run the powershell deployment script to deploy to my host over sftp.

All in under 2 minutes!

 

PHP 5.5 drops support for Windows XP / Server 2003

PHP 5.5 will no longer support Windows XP and 2003. Those systems are around a decade old, so PHP is pulling the plug on them.

It was already mentioned on the PHP 5.4 release changelog. It makes sense, but I’m sure it will cause some issues with organisations who have not been paying attention. I would encourage all developers to sign up for the PHP Announcements mailinglist.

 

Modern technology

Today’s experience of trying to watch the formula 1 race at Silverstone was a frustration of modern technology and drm issues:

  • the Virgin media box only recorded the first hour of the BBC Broadcast. Disappointed.
  • I then navigated to the Virgin media version of BBC iPlayer. However it does not list Formula 1 races, due to licensing restrictions. sigh annoying.
  • I loaded up the iPhone version of the BBC iPlayer. It has the race but it visually it looks like an amateur YouTube video. Connecting it to the HDTV with the Av cable might tell the app to switch to an Hd stream, but alas the picture is twice as muddy. Frustrating.
  • Booted up the laptop to view the web version, which is as blurry as the iPhone version. Let’s download it perhaps it’s higher quality? Hopeful.
  • iPlayer desktop is installed then crashes. Typical.
  • Adobe Air wants to be updated which happens as the programming preventing the update just crashed. Really?
  • iPlayer desktop loads but does not let you browse any shows. Losing interest fast.
  • Downloading Formula one British Gran… 2.3Gb this is looking good. No streaming? I’ll start watching on the iPhone in the meantime. Tolerating.
  • 11 minutes later the abbreviated title expands to ’d prix qualifying’. Getting pissed.
  • downloading the actual grand prix. Watching more on the iPhone. Maybe this is as good as it gets?
  • connecting the laptop over HDMI. Download is finished! Turns out visuals are better but framerate is choppy. Can’t be arsed anymore. I’ll watch it on the laptop.

Does it have to be this hard, Virgin, BBC, Acer, Toshiba, Apple?

 

Fixing Samba network-share change notifications

Today a problem came up where the files on my Samba fileshare did not indicate to my Windows system that they were changed. Software that relies on this information such as TortoiseHG and SimpleLESS would not know that the file had changed. This was especially obvious with SimpleLESS which should take the .less file and process it, but wouldn’t.

It turns out that the cause of this is that on the linux system the system time was off by a large margin. Using Arbab Nazar’s article on setting up time synchronization fixed the issue and prevents it from reoccurring.

 

Facebook wants to be your email

Gervase Markham’s writes about the changes to your Facebook profile, where now by default a @facebook address is shown instead of your own email address:

The email instead goes to my Facebook inbox, and I don’t get a notification email to say it’s there.

So this is why Facebook introduced it: They want you to go to their site to check for email. They don’t want to send the messages to your email and have you interact there, they don’t want you to use a search engine to find content, and they don’t want you to use forums and instant messages to talk to people. They don’t want you ever to get the idea to leave the site.

 

Enable SWF files in Mahara

By default the Embedded Media Block allows you to embed FLV and MP3 files into your pages. However Mahara 1.5 also supports the following files:

  • AVI Video File
  • MP4 Video File
  • MPEG Movie
  • Quicktime Movie
  • SWF Flash movie
  • WMV Video File

Site administrators can enable these formats by going into Site Administration > Plugin Administration_ (under Administrator Extensions) > file/internalmedia (under Plugin type: blocktype) > Config. Then simply tick the file types you want to enable for users.

 

Setting up a VM based development system - Part 1

I recently set up a local development server running Ubuntu on VMware player. I thought it would be interesting to document the process and instructions so that it will be useful to others, and you can follow along / correct / improve this guide. On completion of this series you will end up with a complete LAMP local development system..

Installing Ubuntu

You will need:

Install VMware player (VMP). Restart the pc if necessary.

I’m installing the virtual machine on my USB harddisk, this way I can take my whole development with me on the go (home/work) - this is great because you only have to set all this up once, instead of on every machine you plan to use it on.

Start VMP and “Create a New Virtual Machine” and browse to the downloaded .iso. As part of the Easy Install Information write down the login:

username: __________ password: __________ 

Store the VM on your removable drive.

On the Specify Disk Capacity screen you will want to go higher than the recommended disk size, I chose double (40GB). Make sure you have enough free space available, check this before continueing. I went for double the recommended amount as I want to avoid to repartition later. Accept the other defaults and Ubuntu will start. Keep waiting as Easy Install is installing Ubuntu on your behalf.

If you are a chmod 777 user (jackpot settings), this is a great time to read up on file system permissions by reading the article series starting with “Linux File Permission Concepts” (click next in the summary, there are 5 articles in total): http://articles.slicehost.com/2010/7/17/linux-file-permission-concepts

After a restart the login screen appear and after a successful login you will see the desktop. Because we are going to install a bunch of software let’s make sure everything we already have is up to date. Start the update manager > Settings > Ubuntu Software > Other > Select Best Server. This will speed up downloads. Check again and install updates.

Time to read some more, btw have you created a new tag for all these bookmarks yet? When you are finished reading the above articles, here are some really good resources to read later:

You should now have a running Ubuntu system.

(Source: donationcoder.com)

 

Silicon Knights: "used games are cannibalising the industry"

Silicon Knights boss Denis Dyack talks about used games effect on development budgets:

"I don't think as an industry we can afford $300 million budgets. Some games can, don't get me wrong - for a game like Call of Duty, if they had a $100 million budget, or whatever their budget is, they can afford it. That's not the industry, that's sort of a one-off.

Perhaps there is a point after which it makes little sense to spend more money as you simply cannot recoup it in the market. I'm guessing this limit is probably closer to $0 than $300 million.

source Gamesindustry International.

 

I Won The Windows Phone Challenge, But Lost 'Just Because'

This sounds like a situation where I hope some rep from Microsoft will intervene and offer the guy his reward.

via I Won The Windows Phone Challenge, But Lost “Just Because”

 

Piratepad Beta

This is a online document creation tool that you can work on in realtime with other people with chat. Good for notes and documentation or getting feedback where the other party can make amendments in realtime. (click frog to start)

via Piratepad Beta

 

iPhone / iPad workday reminder alarms

IOS tip: I wanted a reminder every workday at a certain time. You can't set these up in Reminder. Nor in Calendar. Only under Clock > Alarms. And these alarms you cannot swipe to dismiss, you have to swipe to unlock the phone then lock it again. Or snooze the alarm from the lock screen. Not nice when driving.

 

Fork webpages

I'm looking for something a bit unusual. Say you are following the instructions for installing a software package (rl example: http://library.linode.com.../webmin/installing-webmin). Now you find out the instructions are outdated, or incomplete.

How do you keep your notes/additional instructions together with the original? Now you have two problems, your instructions and the original can be updated independently. What happens when the original is updated, or a new version of the software is released?

Wouldn't it be great if you could fork the webpage and update it (or even submit a pull request to the maintainer)?

Is there any practical way of working this way - or will I be stuck with a notetaker / blog / bunch of outdated textfiles?

A lot of questions - maybe one of you has the answer.

 

Link: Stop paying your jQuery tax

Speed up your jQuery powered site by moving scripts to the footer.

Turns out that pushing jQuery to the footer is quite easy for the common case. If all we want is a nice $.ready function that we have accessible everywhere we can explicitly define it without jQuery. Then we can pass the functions we capture to jQuery later on after it loads.

The big lesson learned is that we could avoided this whole problem if we started off with my proposed helper.

via Stop paying your jQuery tax.

 

What Happens When You Swear At Your Users

A valuable lesson for anyone running a website:

After working out a few technical kinks and several botched emails, thanks to missing line breaks, we sent out a final test email to ourselves.  Unfortunately, it went out to every user 

fetchworthy notes • What Happens When You Swear At Your Users.

 

Hide elements that will be shown by jQuery later

I stumbled upon this gem by Jerph on Stackoverflow:

Right after the body tag, put a script tag with this javascript:

jQuery('body').addClass('js');

This gives you a style hook for any elements that will look different in some way when Javascript enabled, and it happens immediately.

via css - Hide jQuery Accordion while loading - Stack Overflow.

 

Preprocessing CCK field output

So I spent a totally unproductive morning figuring out how to override a single field's output in Drupal without rewriting my complete template code for the content type - I want to keep using the $content variable. After many a fruitless attempt luckily Grag Harvey has the answer:

Actually, control over CCK fields can be gained using CCK's own templates.

Consider the situation where your field is called field_test.

Copy content-field.tpl.php to your theme directory and copy it again for the field whose mark-up you wish to alter, naming it content-field-field_test.tpl.php in this case.

Then change the mark-up in the file and it will alter the output of that specific CCK field.

No need to touch node.tpl.php!

Adapted via greg.harvey's answer at node.tpl.php | Drupal API.

 

Project Cars

Sign up to WMD, the somewhat unfortunate acronym chosen for Slightly Mad's World of Mass Development platform, and you're granted access to regularly released builds of the game, which you're then free to pick apart in the official forums. That feedback then gets absorbed by Slightly Mad Studios, a simple loop that means that, when the game is eventually released, it'll be as much a product of the community as it is of the studio.

via Project Cars Preview • Eurogamer.net.

Looks like an interesting development strategy, made famous by Minecraft.

 

Asynchronous UIs - the future of web user interfaces

Discovered this javascript MVC framework SpineJS. The ToDo app is extremely impressive. Try and manipulate items as quickly as possible. Tthen close and reopen the browser. Nice.

via Asynchronous UIs - the future of web user interfaces.

 

The price of a messy codebase: No LaTeX for the iPad

The price of a messy codebase: No LaTeX for the iPad - Valletta Ventures.

The first step in compiling WEB code is to run TANGLE to produce unhelpful Pascal source files. Thoughtfully the TeX build system includes a translator to produce compilable C files. Although WEB was hugely influential as the progenitor of modern source code documentation it is now obsolete, and modern extensions to TeX have been written in C. This is compiled alongside the translated WEB code. It is not hard to imagine the effect this has on the readability of the codebase.

Why programming is not yet as advanced as nature in evolution.

 

Combining multiple Subversion repositories

This post describes a step by step guide on how to combine multiple Subversion repositories whilst keeping individual history (and commit messages).

Dumping

Exporting from pagefeedbacktool repository the /trunk/public folder and integrating that into the services repository under /trunk/public/pagefeedback:

Dump the repository including only /trunk/public as follows:

E:\\Repositories\\pagefeedbacktool>svnadmin dump .| svndumpfilter include --drop-empty-revs --renumber-revs trunk/public > ..\\services\\filtered.dump

Loading

However as pathnames are stored as part of the dump (and replacing the path with a texteditor corrupts the dump), we have to include the full path under a different parent directory:

In VisualSVN create a /trunk/public/pagefeedback/trunk/public folder structure (try without the final public if import fails) then load the dump as follows:

E:\\Repositories\\services>svnadmin load . --parent-dir "trunk/public/pagefeedback" < filtered.dump

The dump is successful but at the wrong path:

currently: /trunk/public/pagefeedback/trunk/public
should be: /trunk/public/pagefeedback/

Post-correction

Open two Windows Explorer windows with both paths side by side, select all the files that should be moved, then RIGHT click drag them to the destination folder and choose SVN Move versioned files here...

Commit from the repository root.

It is now safe to remove the trunk/public folders under /trunk/public/pagefeedback/

Commit again.