Make AddMouseRegion's index unsigned
[dockapps.git] / wmwebcam / wmwebcam.pl
blob15d9517c41e7ab9220d34af97d16042823ca8bd9
1 #!/usr/bin/perl
3 # this script checks if the ppp connection is on and then stamps the
4 # images and sends them to the webserver
6 # check if the ppp is on before stamping&sending, otherwise don't do
7 # anything
8 $areweonline = `grep "ppp" /proc/net/route`;
10 if (length $areweonline != 0) { # THIS IS JUST MY CONFIGURATION,
11 # CHANGE TO YOUR OWN
13 system "stamp"; # stamp reads /tmp/wmwebcam.jpg and outputs
14 # /tmp/webcam.jpg with some info (has to be
15 # configured to do so)
16 # get stamp from:
17 # http://sourceforge.net/projects/stamp
19 # NOTE: stamp has the ability to send the image to server via ftp, but I
20 # prefer using scp.
22 system "scp -q /tmp/webcam.jpg SOME_HOST:public_html/webcam.jpg";
23 # replace the previous line to suit your needs
24 # or disable if you use stamp's own ftpsend
25 } else {
26 # don't do anything