summaryrefslogtreecommitdiffstats
path: root/easyinstall.sh
blob: 40fa85cfe3f87129b2db12cda14be9f9307c73c8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

PLATFORM=$(uname -m)

echo "Identifying platform: $PLATFORM"
case $PLATFORM in 
	"i686") DOWNLOADURL="http://builds.cuberite.org/job/MCServer%20Linux%20x86/lastSuccessfulBuild/artifact/MCServer.tar" ;;
	"x86_64") DOWNLOADURL="http://builds.cuberite.org/job/MCServer%20Linux%20x64/lastSuccessfulBuild/artifact/MCServer.tar" ;;
	# Assume that all arm devices are a raspi for now.
	arm*) DOWNLOADURL="http://builds.cuberite.org/job/MCServer%20Linux%20armhf/lastSuccessfulBuild/artifact/MCServer/MCServer.tar"
esac

echo "Downloading precompiled binaries."
curl -s $DOWNLOADURL | tar -xzf -
echo "Done."

echo "MCServer is now installed, run using 'cd MCServer; ./MCServer'."