blob: d91a2601009949966db0c82ac8bf676916943315 (
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
38
39
40
41
42
43
44
45
|
# Maintainer: George Rawlinson <george@rawlinson.net.nz>
_gemname=tzinfo-data
pkgname=ruby-$_gemname
pkgver=1.2023.3
pkgrel=1
pkgdesc='Timezone data for ruby-tzinfo'
arch=('x86_64')
url='https://github.com/tzinfo/tzinfo-data'
license=('MIT')
depends=('ruby' 'ruby-tzinfo')
options=('!emptydirs')
source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem")
noextract=("$_gemname-$pkgver.gem")
sha512sums=('5a7d5e745f581cfae3c4d1729bdd1697b1ee44454336a9f7192d22e31d04ce57dbf369d6777ab64b197af74276d384276c53376b457851bc67e50ec8d662e099')
b2sums=('5e290a99ceeec5ac3a46372100e9220a74c0d82c0735a718cc52240fcec9feab20172b9e5788380251fc5600957e95aa31ac928b0dcfced73daee1d70f3b131e')
package() {
local _gemdir="$(ruby -e'puts Gem.default_dir')"
gem install \
--verbose \
--ignore-dependencies \
--no-document \
--no-user-install \
--install-dir "$pkgdir/$_gemdir" \
--bindir "$pkgdir/usr/bin" \
"$_gemname-$pkgver.gem"
# delete cache
cd "$pkgdir/$_gemdir"
rm -rf cache
# delete unnecessary files & folders
cd "gems/$_gemname-$pkgver"
find . -type f -name ".*" -delete
# move documentation
install -vd "$pkgdir/usr/share/doc/$pkgname"
mv *.md "$pkgdir/usr/share/doc/$pkgname"
# move license
install -vd "$pkgdir/usr/share/licenses/$pkgname"
mv LICENSE "$pkgdir/usr/share/licenses/$pkgname"
}
|