This commit is contained in:
parent
edcfc08ec1
commit
b709138f5a
65
maple
65
maple
|
@ -55,7 +55,7 @@
|
|||
#####################################################################################################################
|
||||
|
||||
i=`cat maple|grep -n MARKER|cut -f1 -d":"`;i=$(echo $i|xargs|cut -f2 -d" ");ii=`wc -l maple|cut -f1 -d" "`;
|
||||
iii=$((ii-i));tail -n $iii $0>mpl;MD5=$(md5sum mpl|cut -f1 -d ' ');rm mpl;DM5="7e0d29a363b741ce5af25a58fe8ceecf";
|
||||
iii=$((ii-i));tail -n $iii $0>mpl;MD5=$(md5sum mpl|cut -f1 -d ' ');rm mpl;DM5="fdba77ea9e5d7d1966541ee9883e41d1";
|
||||
[ "$MD5" = "$DM5" ] || exit;
|
||||
|
||||
# MARKER ############################################################################################################
|
||||
|
@ -317,27 +317,7 @@ kmodesetup() {
|
|||
fi
|
||||
|
||||
[ "$MODE" = "1" ] && (cp storage/bot/variants/core/maple.ini bot_maple.ini;pip install -r storage/bot/requirements/requirements_core.txt)
|
||||
if [ "$MODE" = "2" ]; then
|
||||
cp storage/bot/variants/dupe/bot_maple__services.py bot_maple.py
|
||||
pip install -r storage/bot/requirements/requirements_services.txt
|
||||
if [ $DISCORD__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $TELEGRAM__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $MATRIX__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
fi
|
||||
[ "$MODE" = "2" ] && (cp storage/bot/variants/dupe/bot_maple__services.py bot_maple.py;pip install -r storage/bot/requirements/requirements_services.txt)
|
||||
[ "$MODE" = "3" ] && (cp storage/bot/variants/dupe/bot_maple__devops.py bot_maple.py;pip install -r storage/bot/requirements/requirements_devops.txt)
|
||||
|
||||
|
||||
|
@ -897,6 +877,27 @@ cmd_setup () {
|
|||
cat plugins/boombox_plugin.py|sed s/"???YOUTUBE???"/"SERVICES_YOUTUBE=True"/g > plugins/boombox_plugin.tmp;mv plugins/boombox_plugin.tmp plugins/boombox_plugin.py
|
||||
cat plugins/youtube_plugin.py|sed s/"???YOUTUBE???"/"SERVICES_YOUTUBE=True"/g > plugins/youtube_plugin.tmp;mv plugins/youtube_plugin.tmp plugins/youtube_plugin.py
|
||||
fi
|
||||
|
||||
|
||||
if [ $DISCORD__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $TELEGRAM__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $MATRIX__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
|
||||
fi;
|
||||
fi;
|
||||
if [ $RESULT -eq 2 ]; then
|
||||
|
@ -988,6 +989,26 @@ cmd_setup_bot () {
|
|||
cat plugins/youtube_plugin.py|sed s/"???YOUTUBE???"/"SERVICES_YOUTUBE=True"/g > plugins/youtube_plugin.tmp;mv plugins/youtube_plugin.tmp plugins/youtube_plugin.py
|
||||
fi
|
||||
|
||||
|
||||
if [ $DISCORD__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???DISCORD???"/"SERVICES_DISCORD=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $TELEGRAM__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???TELEGRAM???"/"SERVICES_TELEGRAM=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
if [ $MATRIX__SERVICING -eq 0 ]; then
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=False"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
else
|
||||
cat bot_maple.py|sed s/"???MATRIX???"/"SERVICES_MATRIX=True"/g > bot_maple.tmp;mv bot_maple.tmp bot_maple.py
|
||||
fi
|
||||
|
||||
|
||||
# injects a myriad of plugins depending on variant
|
||||
cat plugins/net_irc_plugin.py|sed '/includes/r storage/bot/variants/dupe/bot_maple__services__initial_plugins.txt' > plugins/net_irc_plugin.tmp;mv plugins/net_irc_plugin.tmp plugins/net_irc_plugin.py
|
||||
|
||||
|
|
Loading…
Reference in New Issue