27 September 2010
  • Chancel Repair Liability is Fun – I came across this while buying our first property last year, I didn’t quite believe it at first as it’s such an odd situation. Thankfully it didn’t affect our property! (0) #

26 September 2010

Using SVN revision as software version via Ant

Posted: September 26th, 2010 | Author: Jon | Filed under: Development | Tags: , , , | No Comments »

I use Subversion for my personal projects and web sites and for one of my projects I wanted to use the SVN revision value as the version number for the project. As it’s a Java based project and I’m using an Ant script to package & deploy it I wanted to retrieve the repository revision in the Ant script and automatically set the version value in the configuration file. After a bit of searching I found this article on how to get the revision value via Ant, all it requires is that the command line version of Subversion is installed.

So I added the following target to my Ant script to retrieve the last changed revision (slightly modified from the original):

<target name="svnrevision">
	<exec executable="svnversion" outputproperty="repository.revision">
		<arg value="-c" />
		<redirector>
			<outputfilterchain>
				<tokenfilter>
					<replaceregex pattern="[0-9]+\:" replace="" />
					<replaceregex pattern="[M]" replace="" />
				</tokenfilter>
			</outputfilterchain>
		</redirector>
	</exec>
        <echo message="Current revision is ${repository.revision}" />
</target>

Then later on in my Ant script I use the extracted variable to set the version value in the version.properties file while copying it:

<copy file="./src/version.properties" tofile="./deploy/version.properties">
	<filterset>
		<filter token="version" value="${repository.revision}" />
	</filterset>
</copy>

The version.properties file simply has the following line in it:

version=@version@

And that’s it.


23 September 2010
  • Project Cartoon – makes me smile every time I see this as it’s so true. I love the “business consultant” one! (0) #
  • Dev Derby 2010 – good to see Team Java won the challenge. Shows that Java can compete with PHP, Ruby & Python as it see to be getting a lot of bad press at the moment. (1) #

22 September 2010

Asprox botnet SQL Injection attack

Posted: September 22nd, 2010 | Author: Jon | Filed under: System Administration | Tags: , , , | No Comments »

I stumbled across this article by the The Inquirer the other day on the SQL injection attacks by the Asprox botnet. An old classic ASP site of mine actually got hit back in 2008 by it and it looks like it’s still doing the rounds now. Here are some links I found useful at the time including a script I used to help me clean up the infection:


21 September 2010

CCNA Semester 1

Posted: September 21st, 2010 | Author: Jon | Filed under: Life | Tags: , , , | No Comments »

Eight years after my first attempt I was back at Llandrillo College tonight to start Semester 1 of the CCNA course. I’ve been close to starting the course again the past few years but not got round to it for one reason or another. I’m determined to complete the course this time round and looking forward to filling in some of the gaps in my networking knowledge.

It felt good to be back at college again, a lot has changed about the place in the past 12 years since I was first there but some the rooms haven’t changed that much and still bring back a lot of good memories.

Android LifeSaver

Posted: September 21st, 2010 | Author: Jon | Filed under: Technology | Tags: , , , , , , , | No Comments »

Last week I upgraded my mobile from the HTC Magic to the HTC Desire (I might get round to posting a review sometime) direct with Vodafone. While all my contacts, e-mails and calendar entries are stored in the cloud by Google my text messages aren’t and these are equally important to me. Thankfully I came across the LifeSaver app by Tim Bray a while ago and it came in very handy!

It backs up your text messages and call log to your MicroSD card which you can transfer to your new phone and restore them from. Very basic app but it does the job perfectly.