2021-07-31 21:50:21 +00:00
|
|
|
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
|
|
|
|
|
|
|
|
_gemname=parser
|
|
|
|
pkgname=ruby-$_gemname
|
2021-12-08 16:38:23 +00:00
|
|
|
pkgver=3.0.3.2
|
2021-07-31 21:50:21 +00:00
|
|
|
pkgrel=1
|
|
|
|
pkgdesc="A production-ready Ruby parser written in pure Ruby"
|
|
|
|
arch=('any')
|
|
|
|
url="https://github.com/whitequark/parser"
|
|
|
|
license=('MIT')
|
|
|
|
depends=('ruby' 'ruby-ast')
|
|
|
|
makedepends=('ruby-rdoc')
|
|
|
|
options=('!emptydirs')
|
|
|
|
source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem")
|
|
|
|
noextract=("$_gemname-$pkgver.gem")
|
2021-12-08 16:38:23 +00:00
|
|
|
sha512sums=('eee78f29e19632288348b461cef051138a0ce9cf8b890384a33caebeed909c24d9a8df38c68f0ff378bec4a2951112292b61ed6e5e33b18d430f58be5f61f109')
|
|
|
|
b2sums=('33d05085403758fff18b8e6a914e050fd737aecccced739f5b323b66b3a8943f6fcebefa0d63afa870fe1ce271304370f1f575e4b2f08e02e0154a5d1354817c')
|
2021-07-31 21:50:21 +00:00
|
|
|
|
|
|
|
package() {
|
|
|
|
local _gemdir="$(ruby -e'puts Gem.default_dir')"
|
|
|
|
|
|
|
|
gem install \
|
|
|
|
--verbose \
|
|
|
|
--ignore-dependencies \
|
|
|
|
--no-user-install \
|
|
|
|
--install-dir "$pkgdir/$_gemdir" \
|
|
|
|
--bindir "$pkgdir/usr/bin" \
|
|
|
|
"$_gemname-$pkgver.gem"
|
|
|
|
|
|
|
|
# delete cache
|
|
|
|
cd "$pkgdir/$_gemdir"
|
|
|
|
rm -vrf cache
|
|
|
|
|
|
|
|
# delete unnecessary files & folders
|
|
|
|
cd "gems/$_gemname-$pkgver"
|
|
|
|
rm -vrf "$_gemname.gemspec"
|
|
|
|
|
|
|
|
# move license
|
|
|
|
install -vd "$pkgdir/usr/share/licenses/$pkgname"
|
|
|
|
mv -vt "$pkgdir/usr/share/licenses/$pkgname" LICENSE.txt
|
|
|
|
}
|