# Maintainer: Jesus E. pkgbase=penlight pkgname=('lua-penlight') pkgver=1.3.2 pkgrel=1 pkgdesc='Lua libraries focusing on input data handling' arch=('any') url='https://github.com/stevedonovan/penlight' license=('Expat') depends=('lua' 'lua-filesystem') source=("$pkgname-$pkgver.tar.gz::https://github.com/stevedonovan/penlight/archive/$pkgver.tar.gz") sha512sums=('2d9ded6c8d29385ddebbb712626c6ee2989e6a0228e02a33eb1be663e916004e50b08933a25798f3e153dc0d0f4feddce9c397e6b6b86198a11d0b169ac3afae') check() { cd Penlight-$pkgver export LUA_PATH="$PWD/lua/?/init.lua;$PWD/lua/?.lua;$(lua -e 'print(package.path)')" lua run.lua } package_lua-penlight() { cd Penlight-$pkgver install -dm755 "$pkgdir/usr/share/lua/5.3/pl" install -m644 lua/pl/* "$pkgdir/usr/share/lua/5.3/pl" # copy docs install -dm755 "$pkgdir/usr/share/doc/$pkgname/"{,manual,examples} install -m644 CONTRIBUTING.md CHANGES.md README.md "$pkgdir/usr/share/doc/$pkgname" install -m644 doc/manual/* "$pkgdir/usr/share/doc/$pkgname/manual" install -m644 examples/* "$pkgdir/usr/share/doc/$pkgname/examples" # copy license install -Dm644 LICENSE.md -t "$pkgdir/usr/share/licenses/$pkgname" }