1
0
Fork 0
mirror of https://gitlab.alpinelinux.org/alpine/aports.git synced 2025-07-23 03:05:48 +03:00
aports/community/sqlint/APKBUILD
2021-07-03 15:37:40 +02:00

47 lines
1.3 KiB
Text

# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=sqlint
_gemname=sqlint
pkgver=0.2.0
pkgrel=0
pkgdesc="Simple SQL linter supporting ANSI and PostgreSQL syntaxes"
url="https://github.com/purcell/sqlint"
# x86, armhf, armv7, mips64, s390x and riscv64 blocked by ruby-pg_query
arch="noarch !x86 !armhf !armv7 !mips64 !s390x !riscv64"
license="MIT"
depends="ruby ruby-pg_query"
checkdepends="ruby-rspec"
makedepends="ruby-dev"
source="https://github.com/purcell/sqlint/archive/$pkgver/$pkgname-$pkgver.tar.gz
gemspec.patch
"
build() {
gem build $_gemname.gemspec
}
check() {
rspec
}
package() {
local gemdir="$pkgdir/$(ruby -e 'puts Gem.default_dir')"
gem install \
--local \
--install-dir "$gemdir" \
--bindir "$pkgdir/usr/bin" \
--ignore-dependencies \
--no-document \
--verbose \
$_gemname
# Clean-up...
rm -r "$gemdir"/cache \
"$gemdir"/build_info \
"$gemdir"/doc \
"$gemdir"/extensions
}
sha512sums="e0f29e8898a47de878790ddaa4a936e5c0b454e08285be13faf87066f67472d07b156b0cc9114ac4e56eb80bb8e1af1770ece4688d39d68a87d070f2b5adfe06 sqlint-0.2.0.tar.gz
ebe98a70c188095847b7e6bd374ac50ae0972a9c2ea970b58478db1715c5ae4db1631f65405a3fc1ab07c3bef3b9a1f9a152c36a22e55ce57a91d93a81226aca gemspec.patch"