Add a better pluign script

This commit is contained in:
destro174
2021-08-23 11:58:28 +02:00
parent 250aeb5d16
commit 765bb8537f
2 changed files with 84 additions and 0 deletions
+31
View File
@@ -0,0 +1,31 @@
#!/usr/bin/env bash
# BEGIN config
PLUGIN_NAME="chatplugin"
# END config
sourceBase=$(dirname $SOURCE)/../
cd "${basedir:-$sourceBase}"
basedir=$(pwd -P)
cd -
function bashColor {
if [ $2 ]; then
echo -e "\e[$1;$2m"
else
echo -e "\e[$1m"
fi
}
function bashColorReset {
echo -e "\e[m"
}
function basedir {
cd "$basedir"
}
function gethead {
git log -1 --oneline
}