summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 66d31899131efcfee960733edd7633bf2c5eaba8 (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
# Contributor: Sergei Lebedev <superbobry@gmail.com>
# Maintainer: Antony Lee <anntzer dot lee at gmail dot com>

pkgname=hg-prompt-hg
pkgver=r142.dc481ce24b60
pkgrel=1
pkgdesc='An "hg prompt" command for viewing Mercurial repository information.'
arch=('any')
url='http://sjl.bitbucket.org/hg-prompt/'
license=('unknown')
depends=('mercurial>=0.9.3')
provides=('hg-prompt')
source=("$pkgname::hg+http://bitbucket.org/sjl/hg-prompt")
md5sums=('SKIP')

# Due to backcompatibility issues, hg-prompt may totally break hg after the
# latter gets updated, so we disable all extensions here.
export HGRCPATH=/dev/null

pkgver() {
    cd "$srcdir/$pkgname"
    printf 'r%s.%s' "$(hg identify -n)" "$(hg identify -i)"
}

package() {
    cd "$srcdir/$pkgname"
    install -m0644 -D prompt.py $pkgdir$(python2 -c 'import hgext; print hgext.__path__[0]')/prompt.py
}