blob: e8d42cc2d5dbd24dd683a3df607f6d535064f3d5 (
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.3
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=('c857b1e7f578e31d9c6b707ecb984148a3f666b711f83c354c178b50550636c3')
sha256sums_aarch64=('5d81f426f6908bf241df2894fd0183e7a3c278b9f39c5dcd651e1d876e581f0d')
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"
}
|