-
Notifications
You must be signed in to change notification settings - Fork 2
/
PKGBUILD
33 lines (26 loc) · 853 Bytes
/
PKGBUILD
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
30
31
32
33
_name=umap-learn
pkgname=python-$_name
pkgver=0.4.3.r.g114c0f0
pkgrel=1
pkgdesc='Uniform Manifold Approximation and Projection'
arch=(any)
url="https://github.com/lmcinnes/umap"
license=(BSD)
depends=(python-scipy python-scikit-learn python-numba)
makedepends=('python-setuptools')
source=("git+https://github.com/lmcinnes/umap.git#branch=0.5dev")
sha256sums=('SKIP')
pkgver() {
cd umap
local _version
local _revision
local _shorthash
_version="$(git -C umap describe --tags --long | awk -F'-' '{ sub(/^n/, "", $1); print $1 }')"
_revision="$(git -C umap describe --tags --match 'N' | awk -F'-' '{ print $2 }')"
_shorthash="$(git -C umap rev-parse --short HEAD)"
printf '%s.r%s.g%s' "$_version" "$_revision" "$_shorthash"
}
package() {
cd umap
python setup.py install --root="$pkgdir" --optimize=1 || return 1
}