Browse Source

addpkg: ruby-listen 3.6.0-1

primary
George Rawlinson 1 year ago
parent
commit
e1f6d7c56a
Signed by: grawlinson
GPG Key ID: E0959FEA8B550539
  1. 45
      ruby-listen/PKGBUILD

45
ruby-listen/PKGBUILD

@ -0,0 +1,45 @@
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
_gemname=listen
pkgname=ruby-$_gemname
pkgver=3.6.0
pkgrel=1
pkgdesc="Listens to file modifications and notifies you about the changes"
arch=('any')
url="https://github.com/guard/listen"
license=('MIT')
depends=(
'ruby'
'ruby-rb-fsevent'
'ruby-rb-inotify'
)
options=('!emptydirs')
source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem")
noextract=("$_gemname-$pkgver.gem")
b2sums=('f0d853b73a38c8a5c3fc444a2a46f33bf7b148cf7718f14e40cd2fc2b7571aa98ba10f6bfdaa58d11b0bc353d726baf7346b29d144c11bd84223e80c7805c94d')
package() {
local _gemdir="$(ruby -e'puts Gem.default_dir')"
gem install \
--ignore-dependencies \
--no-user-install \
--no-document \
--install-dir "$pkgdir/$_gemdir" \
--bindir "$pkgdir/usr/bin" \
"$_gemname-$pkgver.gem"
# delete cache
cd "$pkgdir/$_gemdir"
rm -vrf cache
cd "gems/$_gemname-$pkgver"
# move documentation
install -vd "$pkgdir/usr/share/doc/$pkgname"
mv -vt "$pkgdir/usr/share/doc/$pkgname" *.md
# move license
install -vd "$pkgdir/usr/share/licenses/$pkgname"
mv -vt "$pkgdir/usr/share/licenses/$pkgname" LICENSE.txt
}
Loading…
Cancel
Save