1 #Contributor: Markus M. May <mmay AT javafreedom DOT org>
2 #Maintainer: Yahya Mohajer <yaya_2013 {AT} yahoo {DOT} com >
7 pkgdesc="A Maven Repository Manager."
8 url="http://nexus.sonatype.org"
11 depends=('java-environment')
12 optdepends=('apache: a full featured webserver'
13 'maven: a java project management and project comprehension tool')
16 backup=(opt/nexus/conf/wrapper.conf)
17 conflicts=('java-nexus')
18 provides=('java-nexus' 'nexus')
19 options=(!strip !docs)
21 source=(http://nexus.sonatype.org/downloads/nexus-oss-webapp-${pkgver}-bundle.tar.gz
25 md5sums=('33e61c03bb3668fd4c8f8de97c9b0669'
26 'c9fc1eb5527ce9273c73bd00ae99a887'
27 'c9d8a5454e89c1bdf5de86edcca82c3a')
33 install -d $pkgdir/opt/nexus
35 # Move startup scripts and wrapper
36 if [ $CARCH = 'x86_64' ]; then
37 mv $srcdir/nexus-oss-webapp-${pkgver}/bin/jsw/linux-x86-64 $pkgdir/opt/nexus/bin || return 1
38 elif [ $CARCH = 'i686' ]; then
39 mv $srcdir/nexus-oss-webapp-${pkgver}/bin/jsw/linux-x86-32 $pkgdir/opt/nexus/bin || return 1
43 mv $srcdir/nexus-oss-webapp-${pkgver}/bin/jsw/lib/wrapper-3.2.3.jar $pkgdir/opt/nexus/bin/lib || return 1
45 # deleting unnecessary files before copying them
46 rm -r $srcdir/nexus-oss-webapp-${pkgver}/bin || return 1
48 install $srcdir/nexus $pkgdir/opt/nexus/bin/nexus
50 # move documentation to the right location
51 mkdir -p $pkgdir/usr/share/doc/nexus
52 install $srcdir/nexus-oss-webapp-$pkgver/*.txt $pkgdir/usr/share/doc/nexus
53 rm $srcdir/nexus-oss-webapp-$pkgver/*.txt
55 # move example configuration to the right location
56 mkdir -p $pkgdir/usr/share/doc/nexus/conf
57 mv $srcdir/nexus-oss-webapp-$pkgver/conf/examples $pkgdir/usr/share/doc/nexus/conf
59 mkdir -p $pkgdir/var/lib/nexus
60 mkdir -p $pkgdir/var/run/nexus
62 # copy the source to the final directory
63 cp -a $srcdir/nexus-oss-webapp-${pkgver}/* $pkgdir/opt/nexus || return 1
65 install $srcdir/wrapper.conf $pkgdir/opt/nexus/conf/wrapper.conf || return 1