1 # Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>
5 pkgdesc="Super simple HTTP server that replies a fixed body with a fixed response code"
7 url="https://github.com/svenstaro/dummyhttp"
12 source=("$pkgname-$pkgver.tar.gz::https://github.com/svenstaro/dummyhttp/archive/v${pkgver}.tar.gz")
13 sha512sums=('57dfeac8f9774d647b7ce09ec6a413f5ca3140500099fda7a7819134146eba105012a629e6e050eedb2ee1ecd026e25ff55bb0acee1fe460f24c8027df6f802a')
16 cd "$srcdir/$pkgname-$pkgver"
18 cargo build --release --locked
22 cd "$srcdir/$pkgname-$pkgver"
24 install -Dm755 target/release/dummyhttp "$pkgdir"/usr/bin/dummyhttp
26 mkdir -p "$pkgdir"/usr/share/{bash-completion/completions,zsh/site-functions,fish/vendor_completions.d}
27 target/release/dummyhttp --print-completions bash > "$pkgdir"/usr/share/bash-completion/completions/dummyhttp
28 target/release/dummyhttp --print-completions zsh > "$pkgdir"/usr/share/zsh/site-functions/_dummyhttp
29 target/release/dummyhttp --print-completions fish > "$pkgdir"/usr/share/fish/vendor_completions.d/dummyhttp.fish
31 mkdir -p "$pkgdir"/usr/share/man/man1
32 target/release/dummyhttp --print-manpage | gzip > "$pkgdir"/usr/share/man/man1/$pkgname.1.gz
34 install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
37 # vim:set ts=2 sw=2 et: