diff options
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 40 |
2 files changed, 60 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..2dcdf276e00c --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = python-sacremoses-git + pkgdesc = Python port of Moses tokenizer, truecaser and normalizer + pkgver = 0.0.35.r41.gb94654f + pkgrel = 1 + url = https://github.com/alvations/sacremoses + arch = any + license = MIT + makedepends = python-setuptools + depends = python-six + depends = python-click + depends = python-joblib + depends = python-tqdm + depends = python-regex + provides = python-sacremoses + conflicts = python-sacremoses + source = python-sacremoses::git+https://github.com/alvations/sacremoses + sha256sums = SKIP + +pkgname = python-sacremoses-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..f4da8580cc6a --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,40 @@ +# Maintainer: Dimitris Kiziridis <ragouel at outlook dot com> + +pkgname=python-sacremoses-git +pkgver=0.0.35.r41.gb94654f +pkgrel=1 +pkgdesc='Python port of Moses tokenizer, truecaser and normalizer' +arch=('any') +url='https://github.com/alvations/sacremoses' +license=('MIT') +provides=('python-sacremoses') +conflicts=('python-sacremoses') +depends=('python-six' + 'python-click' + 'python-joblib' + 'python-tqdm' + 'python-regex') +makedepends=('python-setuptools') +source=("${pkgname%-git}::git+https://github.com/alvations/sacremoses") +sha256sums=('SKIP') + +pkgver() { + cd "${pkgname%-git}" + git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + cd "${pkgname%-git}" + sed -i "s|==|>=|" requirements.txt +} + +build() { + cd "${pkgname%-git}" + python setup.py build +} + +package() { + cd "${pkgname%-git}" + python setup.py install --root="${pkgdir}/" --optimize=1 + install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" +}
\ No newline at end of file |