updated on Thu Jan 26 16:09:46 UTC 2012
[aur-mirror.git] / beets-hg / PKGBUILD
blob80da170dfc75da439d71d067bed8a674aa1ebb12
1 # Maintainer: Adrian Sampson <adrian@radbox.org>
3 python=python2
5 pkgname=beets-hg
6 pkgver=HG
7 pkgrel=1
8 pkgdesc="flexible music library manager and tagger - dev version"
9 arch=('any')
10 url="http://beets.radbox.org/"
11 license=('MIT')
12 depends=('python2-munkres' 'mutagen'
13          'python2-distribute' 'python-unidecode'
14          'python2-musicbrainzngs')
15 makedepends=('mercurial')
16 provides=('beets')
17 conflicts=('beets')
19 _hgroot="https://beets.googlecode.com/hg/"
20 _hgrepo="beets"
22 build() {
23   cd "$srcdir"
24   msg "Connecting to Mercurial server...."
26   if [ -d $_hgrepo ] ; then
27     cd $_hgrepo
28     hg pull -u
29     msg "The local files are updated."
30   else
31     hg clone $_hgroot $_hgrepo
32   fi
34   msg "Mercurial checkout done or server timeout"
35   msg "Starting setup.py build..."
37   rm -rf "$srcdir/$_hgrepo-build"
38   cp -r "$srcdir/$_hgrepo" "$srcdir/$_hgrepo-build"
39   cd "$srcdir/$_hgrepo-build"
41   $python setup.py build || return 1
44 package() {
45   cd "$srcdir/$_hgrepo-build"
46   $python setup.py install --root=$pkgdir
47