summaryrefslogtreecommitdiffstats
path: root/plugins/plugin_examples/sample3Plugin/plugin
diff options
context:
space:
mode:
authorJoel Andres Granados <jgranado@redhat.com>2008-02-25 13:46:06 +0100
committerJoel Andres Granados <jgranado@redhat.com>2008-02-26 14:43:55 +0100
commit6cc51ff0f5c4dda26fc196d0e8db35c525b79844 (patch)
tree2fedf561f86c64e45b060d36f3e3b55c94b78d7e /plugins/plugin_examples/sample3Plugin/plugin
parent74b839ef6a27f25f1e034365cc6ea137dd7368eb (diff)
downloadfirstaidkit-6cc51ff0f5c4dda26fc196d0e8db35c525b79844.tar.gz
firstaidkit-6cc51ff0f5c4dda26fc196d0e8db35c525b79844.tar.xz
firstaidkit-6cc51ff0f5c4dda26fc196d0e8db35c525b79844.zip
Make room in the plugins directory for real plugins.
Move the examples to their own directory.
Diffstat (limited to 'plugins/plugin_examples/sample3Plugin/plugin')
-rwxr-xr-xplugins/plugin_examples/sample3Plugin/plugin41
1 files changed, 41 insertions, 0 deletions
diff --git a/plugins/plugin_examples/sample3Plugin/plugin b/plugins/plugin_examples/sample3Plugin/plugin
new file mode 100755
index 0000000..ba3a5e3
--- /dev/null
+++ b/plugins/plugin_examples/sample3Plugin/plugin
@@ -0,0 +1,41 @@
+#!/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 = "prepare" ]; then
+ echo prepare true
+fi
+if [ $TASK = "diagnose" ]; then
+ echo diagnose false
+fi
+if [ $TASK = "clean" ]; then
+ echo clean 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