2017-06-01 07:52:52 +00:00
|
|
|
#!/bin/sh
|
|
|
|
echo ""
|
|
|
|
echo "NadekoBot Installer started."
|
|
|
|
|
|
|
|
if hash git 1>/dev/null 2>&1
|
|
|
|
then
|
|
|
|
echo ""
|
|
|
|
echo "Git Installed."
|
|
|
|
else
|
|
|
|
echo ""
|
|
|
|
echo "Git is not installed. Please install Git."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
if hash dotnet 1>/dev/null 2>&1
|
|
|
|
then
|
|
|
|
echo ""
|
|
|
|
echo "Dotnet installed."
|
|
|
|
else
|
|
|
|
echo ""
|
|
|
|
echo "Dotnet is not installed. Please install dotnet."
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
2017-06-07 12:07:14 +00:00
|
|
|
root=/opt
|
2017-06-01 07:52:52 +00:00
|
|
|
|
2017-06-07 12:30:18 +00:00
|
|
|
cd "$root"
|
2017-06-01 07:52:52 +00:00
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "Downloading NadekoBot, please wait."
|
|
|
|
git clone -b 1.4 --recursive --depth 1 https://github.com/Kwoth/NadekoBot.git
|
|
|
|
echo ""
|
|
|
|
echo "NadekoBot downloaded."
|
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "Downloading Nadeko dependencies"
|
2017-06-07 12:30:18 +00:00
|
|
|
cd $root/NadekoBot
|
2017-06-07 12:07:14 +00:00
|
|
|
dotnet restore
|
2017-06-01 07:52:52 +00:00
|
|
|
echo ""
|
|
|
|
echo "Download done"
|
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "Building NadekoBot"
|
2017-06-07 12:07:14 +00:00
|
|
|
dotnet build --configuration Release
|
2017-06-01 07:52:52 +00:00
|
|
|
echo ""
|
2017-06-07 12:32:23 +00:00
|
|
|
echo "Building done."
|
2017-06-01 07:52:52 +00:00
|
|
|
|
|
|
|
echo ""
|
|
|
|
echo "Installation Complete."
|
|
|
|
exit 0
|