updated on Tue Jan 10 00:10:07 UTC 2012
[aur-mirror.git] / timebook-hg / PKGBUILD
blob36c54c647ee6879eb303ab4b15cc75e2f7e0dc9f
1 # Contributor: Marcus Fredriksson <drmegahertz@gmail.com>
2 pkgname='timebook-hg'
3 pkgver=64
4 pkgrel=2
5 pkgdesc="Track what you spend time on"
6 url="http://bitbucket.org/trevor/timebook/"
7 license=('MIT')
8 arch=('any')
9 depends=('python2')
10 makedepends=('mercurial' 'python2-distribute')
11 provides=('timebook')
12 source=()
13 md5sums=()
15 _hgroot='http://bitbucket.org/trevor'
16 _hgrepo='timebook'
18 build() {
19         cd "$srcdir"
20     msg "Connecting to Mercurial server..."
22         if [ -d $_hgrepo ]; then
23                 cd $_hgrepo
24                 hg pull -u
25         msg "The local files are updated."
26         else
27                 hg clone ${_hgroot}/${_hgrepo}
28                 cd $_hgrepo
29         fi
31     msg "Mercurial checkout done or server timeout."
32     msg "Building package..."
33     python2 setup.py install --root="$startdir"/pkg --optimize=1 || return 1
35     msg "Adding documentation..."
36     install -D -m644 "$srcdir"/timebook/README "$pkgdir"/usr/share/doc/timebook/README