summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 59f0b2d75d627e2de60892e5f5a76ca16facd661 (plain)
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
# Maintainer of this PKGBUILD file: mehalter <micah at mehalter.com>
# Contributor of this PKGBUILD file: Martino Pilia <martino.pilia@gmail.com>
pkgname=write-good
pkgver=1.0.8
pkgrel=2
pkgdesc="Naive linter for English prose"
arch=('any')
url="https://github.com/btford/write-good"
license=('MIT')
depends=('nodejs')
makedepends=('npm')
source=("https://registry.npmjs.org/$pkgname/-/$pkgname-$pkgver.tgz")
sha256sums=('f54db3db8db0076fd1c05411c7f3923f055176632c51dc4046ab216e51130221')

package() {
	npm install -g \
		--prefix "$pkgdir"/usr \
		"$srcdir"/$pkgname-$pkgver.tgz

	# Non-deterministic race in npm gives 777 permissions to random directories.
	# See https://github.com/npm/npm/issues/9359 for details.
	find "${pkgdir}"/usr -type d -exec chmod 755 {} +

	install -D -m644 \
		"${srcdir}/package/LICENSE" \
		"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}