# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
# Contributor: Artem Vorotnikov <artem@vorotnikov.me>
_gemname=rspec-core
pkgname=ruby-${_gemname}
pkgver=3.12.2
pkgrel=1
pkgdesc='RSpec runner and formatters'
url='https://github.com/rspec/rspec-core'
arch=('any')
license=('MIT')
depends=('ruby-rspec-support')
options=('!emptydirs')
source=(https://rubygems.org/downloads/${_gemname}-${pkgver}.gem)
noextract=(${_gemname}-${pkgver}.gem)
sha512sums=('b798d0624eb53ca866a76cac74885bfb37a2715d21346e097c0a9282a10581219cb7305212f89b14fc57f90fbc03fbd2655079c764902c556b7f174415c9e295')
package() {
local _gemdir="$(gem environment gemdir)"
gem install --ignore-dependencies --no-user-install -i "${pkgdir}${_gemdir}" -n "${pkgdir}/usr/bin" ${_gemname}-${pkgver}.gem
install -Dm 644 "${pkgdir}${_gemdir}/gems/${_gemname}-${pkgver}/LICENSE.md" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
install -Dm 644 "${pkgdir}${_gemdir}/gems/${_gemname}-${pkgver}/README.md" "${pkgdir}/usr/share/doc/${pkgname}/README"
rm "${pkgdir}/${_gemdir}/cache/${_gemname}-${pkgver}.gem"
}
# vim: ts=2 sw=2 et: