blob: 9f6e1acee45708043e8980c7565b09d51c8cfba2 (
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
# Contributor: Chloe Kudryavtsev <toast@toastin.space>
# Maintainer: Chloe Kudryavtsev <toast@toastin.space>
pkgname=skim
pkgver=0.6.9
pkgrel=0
pkgdesc="Fuzzy finder in rust"
url="https://github.com/lotabout/skim"
arch="x86_64" # limited by rust/cargo
license="MIT"
makedepends="cargo"
options="net"
subpackages="
$pkgname-doc
$pkgname-tmux::noarch
$pkgname-vim-plugin:vim:noarch
$pkgname-bash-completion:bash:noarch
$pkgname-zsh-completion:zsh:noarch
$pkgname-bash-keybinds:bashkey:noarch
$pkgname-fish-keybinds:fishkey:noarch
$pkgname-zsh-keybinds:zshkey:noarch
"
source="$pkgname-$pkgver.tar.gz::https://github.com/lotabout/skim/archive/v$pkgver.tar.gz"
export CARGO_HOME="$srcdir"/cargo
build() {
cargo build \
--release \
--verbose
}
check() {
cargo test --all \
--release \
--verbose
}
package() {
install -Dm755 target/release/sk bin/sk-tmux -t "$pkgdir"/usr/bin
install -Dm644 man/man1/sk.1 -t "$pkgdir"/usr/share/man/man1/
install -Dm644 man/man1/sk-tmux.1 -t "$pkgdir"/usr/share/man/man1/
install -Dm644 plugin/skim.vim -t "$pkgdir"/usr/share/vim/vimfiles/plugin
install -Dm644 shell/completion.bash "$pkgdir"/usr/share/bash-completion/completions/sk
install -Dm644 shell/completion.zsh "$pkgdir"/usr/share/zsh/site-functions/_sk
install -Dm644 shell/key-bindings.* -t "$pkgdir"/usr/share/"$pkgname"
}
vim() {
depends=""
pkgdesc="Vim plugin for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel vim"
mkdir -p "$subpkgdir"/usr/share
mv "$pkgdir"/usr/share/vim "$subpkgdir"/usr/share
}
tmux() {
depends="bash"
pkgdesc="tmux launcher for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel tmux"
mkdir -p "$subpkgdir"/usr/bin
mv "$pkgdir"/usr/bin/sk-tmux "$subpkgdir"/usr/bin
}
bash() {
depends=""
pkgdesc="Bash completion for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
mkdir -p "$subpkgdir"/usr/share/bash-completion/completions
mv "$pkgdir"/usr/share/bash-completion/completions/* \
"$subpkgdir"/usr/share/bash-completion/completions
}
zsh() {
depends=""
pkgdesc="Zsh completion for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel zsh"
mkdir -p "$subpkgdir"/usr/share/zsh/site-functions
mv "$pkgdir"/usr/share/zsh/site-functions/* \
"$subpkgdir"/usr/share/zsh/site-functions
}
bashkey() {
depends=""
pkgdesc="Bash key-bindings for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel bash"
mkdir -p "$subpkgdir"/usr/share/skim
mv "$pkgdir"/usr/share/skim/key-bindings.bash "$subpkgdir"/usr/share/skim
}
fishkey() {
depends=""
pkgdesc="Fish key-bindings for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel fish"
mkdir -p "$subpkgdir"/usr/share/skim
mv "$pkgdir"/usr/share/skim/key-bindings.fish "$subpkgdir"/usr/share/skim
}
zshkey() {
depends=""
pkgdesc="Zsh key-bindings for $pkgname"
install_if="$pkgname=$pkgver-r$pkgrel zsh"
mkdir -p "$subpkgdir"/usr/share/skim
mv "$pkgdir"/usr/share/skim/key-bindings.zsh "$subpkgdir"/usr/share/skim
}
sha512sums="487245f4d66c2bd1d3c6c5e69b12593905c4177cb8eaf9f2e69a61946ee1181cf8a3b0f0ed3226d442c6b60dbf539d990e0d0f1a1f2edf575154ba05180afa24 skim-0.6.9.tar.gz"
|