aboutsummaryrefslogtreecommitdiff
path: root/lib/arg_processing.sh
diff options
context:
space:
mode:
authorCody Hiar <chiar@hybridforge.com>2015-08-12 12:06:23 -0600
committerCody Hiar <chiar@hybridforge.com>2015-08-12 12:06:23 -0600
commit07fc2644a237187dd4c5680e88f4adadbf533603 (patch)
treebb6335e180df48c5a6f0b893312857d36ad470f7 /lib/arg_processing.sh
Initial commit of the working files
Diffstat (limited to 'lib/arg_processing.sh')
-rw-r--r--lib/arg_processing.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/arg_processing.sh b/lib/arg_processing.sh
new file mode 100644
index 0000000..d8fb92c
--- /dev/null
+++ b/lib/arg_processing.sh
@@ -0,0 +1,9 @@
+#! Check script arguments.
+
+check_arg_side() {
+ local side="$1"
+ if ! [ "$side" == "left" -o "$side" == "right" ]; then
+ echo "Argument must be must be the side to handle {left, right} and not \"${side}\"."
+ exit 1
+ fi
+}