summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 62ac476f7e1ad195f20d014952db4fa0174f6288 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
pkgname=django-storages-hg
pkgver=280
pkgrel=1
pkgdesc="Collection of custom storage backends for Django"
arch=('any')
url="http://code.larlet.fr/django-storages/"
license=('BSD3')
depends=('python2-django' 'python2-boto')
makedepends=('mercurial')

_hgroot="https://bitbucket.org/david/django-storages"
_hgrepo="django-storages"
_hgbranch="default"

build() {
	 hg --cwd ${_hgrepo} update -C || \
		  hg clone -b ${_hgbranch} "${_hgroot}/${_hgrepo}" ${_hgrepo}
	 cd ${_hgrepo}
	 if (( $(hg id -n) < $(hg id -nr ${_hgbranch}) )); then
		  printf 'You are not building the latest revision!\n'
		  printf "Consider updating _hgrev to $(hg id -r ${_hgbranch}).\n"
	 fi
	 python2 setup.py build
}

package() {
	 cd ${_hgrepo}
	 python2 setup.py install --root="$pkgdir" --optimize=1
}