From af224bbb8dc9aea0431afba204cf4f80eb78deb6 Mon Sep 17 00:00:00 2001
From: Henrik Brix Andersen <henrik@brixandersen.dk>
Date: Tue, 31 Jul 2012 22:48:47 +0200
Subject: [PATCH] Add example on how to use post-processing scripts for sending
 custom notification when slicing is done.

---
 utils/post-processing/prowl-notification.pl | 21 +++++++++++++++++++++
 1 file changed, 21 insertions(+)
 create mode 100755 utils/post-processing/prowl-notification.pl

diff --git a/utils/post-processing/prowl-notification.pl b/utils/post-processing/prowl-notification.pl
new file mode 100755
index 000000000..5a5e1ca53
--- /dev/null
+++ b/utils/post-processing/prowl-notification.pl
@@ -0,0 +1,21 @@
+#!/usr/bin/perl
+#
+# Example post-processing script for sending a Prowl notification upon
+# completion. See http://www.prowlapp.com/ for more info.
+
+use strict;
+use warnings;
+
+use File::Basename qw(basename);
+use WebService::Prowl;
+
+# set your Prowl API key here
+my $apikey = '';
+
+my $file = basename $ARGV[0];
+my $prowl = WebService::Prowl->new(apikey => $apikey);
+my %options = (application => 'Slic3r',
+               event =>'Slicing Done!',
+               description => "$file was successfully generated");
+printf STDERR "Error sending Prowl notification: %s\n", $prowl->error
+    unless $prowl->add(%options);