blob: 6f29b9755ed6d656be1733a12141d92a32921c89 (
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
28
29
30
31
32
|
# Maintainer: Douglas Chimento <dchimento@gmail.com>
_npmname=balanceofsatoshis
_npmver=17.5.3
pkgname="balance-of-satoshis"
pkgver=${_npmver}
pkgrel=1
pkgdesc="Commands for working with LND balances."
arch=(any)
url="https://github.com/alexbosworth/balanceofsatoshis"
license=("MIT")
depends=("nodejs>=10")
makedepends=("npm")
optdepends=('lnd-bin')
source=("https://registry.npmjs.org/$_npmname/-/$_npmname-$_npmver.tgz")
noextract=("$_npmname-$_npmver.tgz")
sha256sums=(97b8a6b72705ef3022cf09d45bb7f98004293b873677919bc2e8daba20b9f1f4)
options=('!strip')
package() {
npm install -g --prefix "${pkgdir}/usr" --cache "${srcdir}/npm-cache" "${srcdir}/$_npmname-$_npmver.tgz"
# Non-deterministic race in npm gives 777 permissions to random directories.
# See https://github.com/npm/cli/issues/1103 for details.
find "${pkgdir}/usr" -type d -exec chmod 755 {} +
# npm gives ownership of ALL FILES to build user
# https://bugs.archlinux.org/task/63396
chown -R root:root "${pkgdir}"
install -d -m755 "$pkgdir/usr/share/bash-completion/completions"
install -d -m755 "$pkgdir/usr/share/zsh/site-functions"
$pkgdir/usr/bin/bos completion bash > "$pkgdir/usr/share/bash-completion/completions/bos"
$pkgdir/usr/bin/bos completion zsh > "$pkgdir/usr/share/zsh/site-functions/_bos"
}
|