How to Make the Recovery Partition Visible in Disk Utility

While teaching a 10.7 Support Essentials course today, one of the delegates asked if it was possible to make the recovery partition visible in Disk Utility in case of any corruption that may need to be repaired.
If you are happy with using the Command Line, I am happy to report that this can easily be achieved by the following command.

sudo asr adjust -target /dev/disk0s3 -settype "Apple_HFS"

Before running this, check that your recovery partition disk identifier is in fact /disk0s3 by running

diskutil list

and checking the disk identifier on the right hand side

To hide the partition again, simply run the command again but change “Apple_HFS” to “Apple_Boot”