blob: b78859ed342cef7e28d320fc364fb9d5e4db23aa (
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
|
pkgname=lefthook-bin
pkgver=1.9.1
pkgrel=1
pkgdesc="git hooks manager"
arch=('x86_64' 'aarch64')
url="https://github.com/evilmartians/lefthook"
license=('MIT')
depends=()
makedepends=()
provides=('lefthook')
conflicts=('lefthook')
source_x86_64=("https://github.com/evilmartians/lefthook/releases/download/v${pkgver}/lefthook_${pkgver}_Linux_x86_64.gz")
source_aarch64=("https://github.com/evilmartians/lefthook/releases/download/v${pkgver}/lefthook_${pkgver}_Linux_arm64.gz")
sha256sums_x86_64=('90df20ea7cd7d7b4b84c73e746a60490cae51a831720d6f9fffe336bfde826ff')
sha256sums_aarch64=('2ed7a88b5bcdb6ed7d9f605051ab5b05e6ffbf25c46adbf858ec67656dfe148f')
build() {
cd "${srcdir}"
mv "lefthook_${pkgver}_Linux_${CARCH}" lefthook
chmod +x lefthook
./lefthook completion zsh >lefthook.zsh
./lefthook completion fish >lefthook.fish
./lefthook completion bash >lefthook.bash
}
package() {
cd "${srcdir}"
# Install lefthook
install -D -m0755 lefthook \
"${pkgdir}/usr/bin/lefthook"
# Install completions
install -Dm644 lefthook.zsh "${pkgdir}/usr/share/zsh/site-functions/_lefthook"
install -Dm644 lefthook.fish "${pkgdir}/usr/share/fish/completions/lefthook.fish"
install -Dm644 lefthook.bash "${pkgdir}/usr/share/bash-completion/completions/lefthook"
}
|