summaryrefslogtreecommitdiff
path: root/etc/dropnroll/sample/newfile.sh
diff options
context:
space:
mode:
Diffstat (limited to 'etc/dropnroll/sample/newfile.sh')
-rwxr-xr-xetc/dropnroll/sample/newfile.sh15
1 files changed, 15 insertions, 0 deletions
diff --git a/etc/dropnroll/sample/newfile.sh b/etc/dropnroll/sample/newfile.sh
new file mode 100755
index 0000000..600b5f1
--- /dev/null
+++ b/etc/dropnroll/sample/newfile.sh
@@ -0,0 +1,15 @@
+#!/bin/sh
+
+DIR=$1
+FILENAME=$2
+SIZE=$3
+
+if [ -z "$FILENAME" ]; then
+ exit 1;
+fi
+
+echo "new file of size $SIZE detected: $DIR/$FILENAME" >> /tmp/dropnroll-sample.log
+sleep 5
+rm -f $DIR/$FILENAME >> /tmp/dropnroll-sample.log 2>&1
+
+exit 0