summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 194a602d35540108ce9b97d6799e325244ccbd8e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Generated by gem2arch (https://github.com/anatol/gem2arch)
# Maintainer : David Phillips <dbphillipsnz@gmail.com>
# Contributor: Hyacinthe Cartiaux <hyacinthe.cartiaux@free.fr>
# Contributor: Anatol Pomozov <anatol.pomozov@gmail.com>

_gemname=rest-client
pkgname=ruby-${_gemname}
pkgver=1.8.0
pkgrel=1
pkgdesc=("Simple HTTP and REST client for Ruby, inspired by the Sinatra microframework style of specifying actions")
arch=("any")
url=("https://github.com/rest-client/rest-client")
license=('MIT')
depends=('ruby>=1.9.2'
         'ruby-http-cookie>=1.0.2'
         'ruby-mime-types>1.16'
         'ruby-netrc>=0.7')
options=("!emptydirs")
source=("https://rubygems.org/downloads/${_gemname}-${pkgver}.gem")
noextract=("${_gemname}-${pkgver}.gem")
sha256sums=('e70e4fe5660181fe5c6909de06f7b716931b433f5748f3713c841be709031fd5')

package() {
	local _gemdir="$(ruby -e'puts Gem.default_dir')"

	gem install \
		--ignore-dependencies \
		--no-user-install \
		-i "${pkgdir}/${_gemdir}" \
		-n "${pkgdir}/usr/bin" \
		"${_gemname}-${pkgver}.gem"
	rm "${pkgdir}/${_gemdir}/cache/${_gemname}-${pkgver}.gem"

	install -D -m644 \
		"${pkgdir}/${_gemdir}/gems/${_gemname}-${pkgver}/LICENSE" \
		"${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}