# Contributor: Leo # Maintainer: pkgname=mdcat pkgver=0.22.1 pkgrel=0 pkgdesc="Cat for markdown" url="https://github.com/lunaryorn/mdcat" arch="all !s390x !mips !mips64" # Limited by cargo license="Apache-2.0" makedepends="cargo openssl-dev" checkdepends="py3-ansi2html" subpackages=" $pkgname-bash-completion $pkgname-zsh-completion $pkgname-fish-completion " source="$pkgname-$pkgver.tar.gz::https://github.com/lunaryorn/mdcat/archive/mdcat-$pkgver.tar.gz" builddir="$srcdir/mdcat-mdcat-$pkgver" build() { cargo build --release --locked } check() { cargo test --release --locked } package() { install -s -Dm0755 target/release/mdcat -t "$pkgdir"/usr/bin # Install the generated shell completion files install -Dm644 "$builddir"/target/release/build/mdcat-*/out/completions/mdcat.bash \ -t "$pkgdir"/usr/share/bash-completion/completions install -Dm644 "$builddir"/target/release/build/mdcat-*/out/completions/_mdcat \ -t "$pkgdir"/usr/share/zsh/site-functions install -Dm644 "$builddir"/target/release/build/mdcat-*/out/completions/mdcat.fish \ -t "$pkgdir"/usr/share/fish/completions } sha512sums="4a3a430ae4f8bdb273e404591703a3a681509bb9a6e88bb3f682cd46ec904ea2cdabab1e273178d58d77229398d0623abc945af34b9b20211bd0291a0f817dfe mdcat-0.22.1.tar.gz"