1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
6 pkgdesc="A markdown parser built for speed"
8 url='https://github.com/chjj/marked'
12 source=(https://registry.npmjs.org/$pkgname/-/$pkgname-$pkgver.tgz)
13 noextract=($pkgname-$pkgver.tgz)
14 sha512sums=('3d1b1a886f386caf8032fc73884fe5085b2cf23b978cd696cd56cde6d5c09b85e379a4bd3401e1a29f8f8d0c73d80f61f10e0cff11a6ccff2fa8dc32e8978ad0')
17 npm install -g --prefix "$pkgdir"/usr "$srcdir"/$pkgname-$pkgver.tgz
19 # Non-deterministic race in npm gives 777 permissions to random directories.
20 # See https://github.com/npm/npm/issues/9359 for details.
21 chmod -R u=rwX,go=rX "$pkgdir"
23 # npm installs package.json owned by build user
24 # https://bugs.archlinux.org/task/63396
25 chown -R root:root "$pkgdir"
27 install -d "$pkgdir"/usr/share/licenses/$pkgname
28 ln -s ../../../lib/node_modules/marked/LICENSE.md "$pkgdir"/usr/share/licenses/$pkgname/LICENSE.md