This code will add some simple but useful features to your Splunk installation