summaryrefslogtreecommitdiffstats
path: root/plugins/sample3Plugin/plugin
diff options
context:
space:
mode:
authorJoel Andres Granados <jgranado@redhat.com>2007-11-21 16:11:14 +0100
committerJoel Andres Granados <jgranado@redhat.com>2007-11-21 16:11:14 +0100
commitf421f2295908b21b877af6705e0ac48d9a2c6455 (patch)
treedbd381dd6f220c4cd636a1581c312d8f1502ecd2 /plugins/sample3Plugin/plugin
parentd39f1d92e4251daca8234591a760c7e31a80ca5d (diff)
downloadfirstaidkit-f421f2295908b21b877af6705e0ac48d9a2c6455.tar.gz
firstaidkit-f421f2295908b21b877af6705e0ac48d9a2c6455.tar.xz
firstaidkit-f421f2295908b21b877af6705e0ac48d9a2c6455.zip
Get the shell/Binary example working.
Diffstat (limited to 'plugins/sample3Plugin/plugin')
-rwxr-xr-xplugins/sample3Plugin/plugin42
1 files changed, 42 insertions, 0 deletions
diff --git a/plugins/sample3Plugin/plugin b/plugins/sample3Plugin/plugin
new file mode 100755
index 0000000..9cf7e03
--- /dev/null
+++ b/plugins/sample3Plugin/plugin
@@ -0,0 +1,42 @@
+#!/bin/bash
+
+# Since this is just an example this will only have default tasks.
+TASK=""
+
+use()
+{
+ echo You are using it wrong.
+}
+
+if [ $1 ] ; then
+ if [ $2 ] ;then
+ TASK=$2
+ else
+ use
+ exit 1
+ fi
+else
+ use
+ exit 1
+fi
+
+
+if [ $TASK = "init" ]; then
+ echo init true
+fi
+if [ $TASK = "diagnose" ]; then
+ echo diagnose false
+fi
+if [ $TASK = "purge" ]; then
+ echo purge true
+fi
+if [ $TASK = "fix" ]; then
+ echo fix true
+fi
+if [ $TASK = "backup" ]; then
+ echo backup true
+fi
+if [ $TASK = "restore" ]; then
+ echo restore true
+fi
+