aboutsummaryrefslogtreecommitdiffstats
path: root/main/mercurial
diff options
context:
space:
mode:
authorSören Tempel <soeren+git@soeren-tempel.net>2016-02-16 00:00:13 +0100
committerSören Tempel <soeren+git@soeren-tempel.net>2016-02-16 00:00:13 +0100
commit40fce3b393de7d70b733c5305099731b4434dc06 (patch)
tree9124c02834213adf7912e2910b27dc591a9218c5 /main/mercurial
parentb72f6a1c5b4cb1d1eeaf679a46887a4bebdcf3e6 (diff)
downloadaports-40fce3b393de7d70b733c5305099731b4434dc06.tar.bz2
aports-40fce3b393de7d70b733c5305099731b4434dc06.tar.xz
main/mercurial: upgrade to 3.7.1
Also create subpackages for zsh, vim and bash related files. Furthermore, hgeditor is now installed by default as well.
Diffstat (limited to 'main/mercurial')
-rw-r--r--main/mercurial/APKBUILD68
1 files changed, 51 insertions, 17 deletions
diff --git a/main/mercurial/APKBUILD b/main/mercurial/APKBUILD
index b07a95893..91b68d59d 100644
--- a/main/mercurial/APKBUILD
+++ b/main/mercurial/APKBUILD
@@ -1,15 +1,20 @@
+# Contributor: Sören Tempel <soeren+alpine@soeren-tempel.net>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=mercurial
-pkgver=3.6.2
+pkgver=3.7.1
pkgrel=0
pkgdesc="A scalable distributed SCM tool"
-url="http://www.selenic.com/mercurial"
+url="https://www.mercurial-scm.org/"
arch="all"
license="GPL2+"
depends=""
makedepends="python-dev"
-subpackages="$pkgname-doc"
-source="http://www.selenic.com/$pkgname/release/$pkgname-$pkgver.tar.gz"
+subpackages="
+ $pkgname-doc
+ $pkgname-vim:vim
+ $pkgname-zsh-completion:zshcomp
+ $pkgname-bash-completion:bashcomp"
+source="https://www.mercurial-scm.org/release/$pkgname-$pkgver.tar.gz"
_builddir="$srcdir"/$pkgname-$pkgver
build() {
@@ -20,17 +25,46 @@ build() {
package() {
cd "$_builddir"
python setup.py install --root="$pkgdir" || return 1
- install -d "$pkgdir"/usr/share/man/man1 "$pkgdir"/usr/share/man/man5
- install -m644 doc/hg.1 ""$pkgdir"/usr/share/man/man1" || return 1
- install -m644 doc/hgrc.5 doc/hgignore.5 "$pkgdir"/usr/share/man/man5 \
- || return 1
- install -m755 contrib/hgk "$pkgdir"/usr/bin || return 1
- install -m644 -D contrib/bash_completion \
- "$pkgdir"/etc/bash_completion.d/hg || return 1
- vimpath="$pkgdir"/usr/share/vim/vimfiles
- install -Dm644 contrib/vim/HGAnnotate.vim \
- "${vimpath}/syntax/HGAnnotate.vim" || return 1
+ install -m755 contrib/hgk hgeditor "$pkgdir"/usr/bin || return 1
+
+ for man in doc/*.?; do
+ install -Dm644 "$man" \
+ "$pkgdir"/usr/share/man/man${man##*.}/${man##*/} || return 1
+ done
+}
+
+vim() {
+ depends=""
+ pkgdesc="Vim syntax for $pkgname"
+ install_if="vim $pkgname=$pkgver-r$pkgrel"
+ arch="noarch"
+
+ cd "$_builddir"/contrib/vim/
+ mkdir -p "$subpkgdir"/usr/share/vim/vimfiles/syntax/
+ install -Dm644 HGAnnotate.vim hgtest.vim \
+ "$subpkgdir"/usr/share/vim/vimfiles/syntax/ || return 1
}
-md5sums="f1155a562652004f569e5564d3c82661 mercurial-3.6.2.tar.gz"
-sha256sums="09c567049c3e30f791db0cf5937346c7ff3568deadf4eb1d4e2f7c80001cb3d6 mercurial-3.6.2.tar.gz"
-sha512sums="2ad780174a30c39a1482d597466523a133b8c62a3a0eb9ac3b183082e279fc624998a9ffa520abafe5f7afc7d9f4600f443ad4dfa1003bd7fdc6b713040091ed mercurial-3.6.2.tar.gz"
+
+zshcomp() {
+ depends=""
+ pkgdesc="Zsh completions for $pkgname"
+ install_if="$pkgname=$pkgver-r$pkgrel zsh"
+ arch="noarch"
+
+ install -Dm644 "$_builddir"/contrib/zsh_completion \
+ "$subpkgdir"/usr/share/zsh/site-functions/_${pkgname} || return 1
+}
+
+bashcomp() {
+ depends=""
+ pkgdesc="Bash completions for $pkgname"
+ install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
+ arch="noarch"
+
+ install -Dm644 "$_builddir"/contrib/bash_completion \
+ "$subpkgdir"/usr/share/bash-completion/completions/${pkgname} || return 1
+}
+
+md5sums="4e922fcc9454d2665f20c3b9b4741add mercurial-3.7.1.tar.gz"
+sha256sums="96d37d1f444a032295e190318b3166e9d05abb55916d2b3adb618a8f16c5cfed mercurial-3.7.1.tar.gz"
+sha512sums="32df161756d7c76abd792bfe5dc3d3f2ea39facdc9c9bd8d93193ecd6cc171f050a4e6dae18255614087ba6fa8f9d787aac41b137c233fa9c3f32217a9cad112 mercurial-3.7.1.tar.gz"