summaryrefslogtreecommitdiff
path: root/botchcli
diff options
context:
space:
mode:
Diffstat (limited to 'botchcli')
-rwxr-xr-xbotchcli17
1 files changed, 17 insertions, 0 deletions
diff --git a/botchcli b/botchcli
new file mode 100755
index 0000000..5dfa0f7
--- /dev/null
+++ b/botchcli
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+SUBCHAR=!
+
+[[ "$*" =~ $SUBCHAR ]] && WORK=$* || WORK="$* $SUBCHAR"
+
+echo -n "[botchcli] $WORK> "
+while read LINE; do
+ if [ "x$LINE" == "x" ] ; then
+ echo -n
+ elif [ "x${LINE,,}" == "xquit" ] ; then
+ exit 0
+ else
+ ${WORK/$SUBCHAR/$LINE}
+ fi
+ echo -n "[botchcli] $WORK> "
+done