1 # Maintainer: Chris Hodapp <clhodapp1@gmail.com>
2 pkgname=craftbukkit-git
5 pkgdesc="Implementation of Bukkit Minecraft Server Mod API (git)"
7 url="http://bukkit.org"
9 depends=('tmux' 'java-runtime')
10 makedepends=('git' 'maven')
11 provides=('craftbukkit')
12 conflicts=('craftbukkit')
13 install=craftbukkit-git.install
14 source=('craftbukkit.sh' 'craftbukkit.rc' 'cbconsole.sh')
15 md5sums=('e92ee0d9faee447d747854460b3c82ac'
16 'aaa4b5beecdfa785c749a6d1691e3e87'
17 'afd4c600d9f0b6c165e3002df08c4a85')
19 _gitroot=https://github.com/Bukkit/CraftBukkit.git
24 msg "Connecting to GIT server...."
26 if [[ -d "$_gitname" ]]
28 cd "$_gitname" && git pull origin
29 msg "The local files are updated."
31 git clone "$_gitroot" "$_gitname"
34 msg "GIT checkout done or server timeout"
35 msg "Starting build..."
36 cd "$srcdir/$_gitname"
37 /opt/maven/bin/mvn dependency:purge-local-repository
38 /opt/maven/bin/mvn package
42 cd "$srcdir/$_gitname"
43 mkdir -p "$pkgdir/opt/craftbukkit/plugins"
44 mkdir -p "$pkgdir/etc/rc.d"
45 mkdir -p "$pkgdir/usr/bin"
46 install -m 644 "$srcdir/craftbukkit/target/craftbukkit-0.0.1-SNAPSHOT.jar" "$pkgdir/opt/craftbukkit"
47 install -m 755 "$srcdir/craftbukkit.sh" "$pkgdir/opt/craftbukkit/craftbukkit"
48 install -m 755 "$srcdir/craftbukkit.rc" "$pkgdir/etc/rc.d/craftbukkit"
49 install -m 755 "$srcdir/cbconsole.sh" "$pkgdir/usr/bin/cbconsole"