diff options
author | libertylocked | 2018-10-11 14:11:52 -0400 |
---|---|---|
committer | libertylocked | 2018-10-11 14:11:52 -0400 |
commit | e5e3691f49f214160e90b4a5567f92adb843f9c4 (patch) | |
tree | 054f873f27e3dbcb24f8328f3269db04b93bf977 | |
parent | b8fbfbf6ae780ab1032d06dbabf80b87e5d09c4d (diff) | |
download | aur-e5e3691f49f214160e90b4a5567f92adb843f9c4.tar.gz |
no more bundled nodejs. now has dep on nodejs
-rw-r--r-- | .SRCINFO | 9 | ||||
-rw-r--r-- | .gitignore | 6 | ||||
-rw-r--r-- | PKGBUILD | 34 | ||||
-rw-r--r-- | bw.sh | 2 |
4 files changed, 28 insertions, 23 deletions
@@ -1,19 +1,22 @@ pkgbase = bitwarden-cli-git pkgdesc = Bitwarden Command-line Interface pkgver = 1.3.0.r21.gbd38107 - pkgrel = 1 + pkgrel = 2 url = https://github.com/bitwarden/cli arch = x86_64 license = GPL3 makedepends = nodejs makedepends = npm + depends = nodejs provides = bitwarden-cli conflicts = bitwarden-cli options = !strip - source = bitwarden-cli-git::git+https://github.com/bitwarden/cli.git - source = jslib::git+https://github.com/bitwarden/jslib.git + source = bitwarden-cli-git-repo::git+https://github.com/bitwarden/cli.git + source = jslib-git-repo::git+https://github.com/bitwarden/jslib.git + source = bw.sh sha512sums = SKIP sha512sums = SKIP + sha512sums = 71729c0ee95429ab03fa586de6bbf8ebad29d6d5544775564bb35eaa68cc4a915007db54b5928e99234bfe7828491829a5d32750f641056a0b68e05aa842f9ee pkgname = bitwarden-cli-git diff --git a/.gitignore b/.gitignore index 6bd95cf313bd..4782637367b7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ pkg/ src/ -bitwarden-cli-git/ -jslib/ -bitwarden-cli-git-1* +bitwarden-cli-git-repo/ +jslib-git-repo/ +bitwarden-cli-git-1.* @@ -3,47 +3,47 @@ pkgname=bitwarden-cli-git _pkgname=bitwarden-cli pkgver=1.3.0.r21.gbd38107 -pkgrel=1 +pkgrel=2 pkgdesc='Bitwarden Command-line Interface' arch=('x86_64') url='https://github.com/bitwarden/cli' license=('GPL3') makedepends=('nodejs' 'npm') +depends=('nodejs') provides=('bitwarden-cli') conflicts=('bitwarden-cli') options=('!strip') -source=("${pkgname}::git+https://github.com/bitwarden/cli.git" - 'jslib::git+https://github.com/bitwarden/jslib.git') +source=("${_pkgname}-git-repo::git+https://github.com/bitwarden/cli.git" + 'jslib-git-repo::git+https://github.com/bitwarden/jslib.git' + 'bw.sh') sha512sums=('SKIP' - 'SKIP') + 'SKIP' + '71729c0ee95429ab03fa586de6bbf8ebad29d6d5544775564bb35eaa68cc4a915007db54b5928e99234bfe7828491829a5d32750f641056a0b68e05aa842f9ee') pkgver() { - cd "${pkgname}" + cd "${_pkgname}-git-repo" git describe --long --tags | sed 's/^v//' | sed 's/\([^-]*-g\)/r\1/;s/-/./g' } prepare() { - cd "${pkgname}" + cd "${_pkgname}-git-repo" git submodule init - git config submodule.jslib.url $srcdir/jslib + git config submodule.jslib.url $srcdir/jslib-git-repo git submodule update } build() { - cd "${pkgname}" - - # Download modules + cd "${_pkgname}-git-repo" npm install - - # Build prod bundle npm run build:prod - - # Build binary - npm run package:lin } package() { - cd "${pkgname}" + cd "${_pkgname}-git-repo" + + install -dm755 "${pkgdir}/usr/lib/${_pkgname}" + cp -a build/. "${pkgdir}/usr/lib/${_pkgname}/" + install -dm755 "${pkgdir}/usr/bin" - install -Dm755 "dist/linux/bw" "${pkgdir}/usr/bin/bw" + install -Dm755 "${srcdir}/bw.sh" "${pkgdir}/usr/bin/bw" } diff --git a/bw.sh b/bw.sh new file mode 100644 index 000000000000..6814da8ae156 --- /dev/null +++ b/bw.sh @@ -0,0 +1,2 @@ +#!/bin/sh +node /usr/lib/bitwarden-cli/bw.js $@ |