42 lines
1.1 KiB
Text
42 lines
1.1 KiB
Text
|
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
|
||
|
|
||
|
_gemname=pastel
|
||
|
pkgname=ruby-$_gemname
|
||
|
pkgver=0.8.0
|
||
|
pkgrel=1
|
||
|
pkgdesc="Terminal output styling with intuitive and clean API"
|
||
|
arch=('any')
|
||
|
url="https://github.com/piotrmurach/pastel"
|
||
|
license=('MIT')
|
||
|
depends=('ruby' 'ruby-tty-color')
|
||
|
options=('!emptydirs')
|
||
|
source=("https://rubygems.org/downloads/$_gemname-$pkgver.gem")
|
||
|
noextract=("$_gemname-$pkgver.gem")
|
||
|
b2sums=('22a0030549e769e9be826046abd47286633b2e3da50c01efb1b9ca1eb37f47255a97634ac40b83b323136d69f85f41e50ec6ed67cfb4699cedd2cc296fd7e56d')
|
||
|
|
||
|
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
|
||
|
}
|