# Contributor: Adam Dobrawy # Maintainer: Adam Dobrawy # Maintainer: HyperOne staff pkgname=h1-cli _pkgname=${pkgname/-cli/} pkgver=1.6.1 pkgrel=0 pkgdesc="Command-line interface for HyperOne platform" url="https://www.hyperone.com/tools/cli/" arch="x86_64" license="MIT" depends="openssh-client" makedepends="nodejs npm" subpackages="rbx-cli:rbx" source="$pkgname-$pkgver.tar.gz::https://github.com/hyperonecom/$pkgname/archive/v$pkgver.tar.gz" options="!strip !check" build() { npm install npx pkg -c ./package.json -t "node12-alpine" -o "./dist/h1" "./bin/h1" npx pkg -c ./package.json -t "node12-alpine" -o "./dist/rbx" "./bin/rbx" } package() { mkdir -p "$pkgdir"/usr/bin cp "$builddir/dist/$_pkgname" "$pkgdir"/usr/bin/$_pkgname } rbx() { pkgdesc="Command-line interface for Rootbox platform" url="http://rootbox.com/" cd "$builddir" mkdir -p "$subpkgdir"/usr/bin cp "$builddir/dist/rbx" "$subpkgdir"/usr/bin/rbx } sha512sums="9043ea20bdc39a60238d94561c48da95f11fda9d57bdd6e9d4802a244ef4df344e72938bfc4e879437c5739d79c83364f1ef0b92ba1f82855896f836b76e7be3 h1-cli-1.6.1.tar.gz"