#!/bin/sh
#If stop command is defined use it
if ! test -z "$MYCROFT_STOP_CMD"; then
	$MYCROFT_STOP_CMD
elif [ -x /opt/mycroft-core/stop-mycroft.sh ]; then
	cd /opt/mycroft-core || exit
	./stop-mycroft.sh
else
	# Use default git install
	cd "$HOME/mycroft-core"|| exit
	./stop-mycroft.sh
fi
