blob: a3ccc93998baf959284ca816e50f0a0217f0bea8 (
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
|
# Maintainer: FlyCat <yanwh0311@gmail.com>
pkgname=v2csub-git
pkgver=20211127
pkgrel=1
pkgdesc="Subscriber for v2ray-core"
arch=('any')
url="https://github.com/yanwh0311/v2csub"
license=(GPL)
makedepends=('git')
depends=('glibc' 'curl' 'coreutils' 'v2ray-rules-dat-git')
optdepends=('v2ray: connecting support')
_gitname=v2csub
_gitroot='https://github.com/yanwh0311/v2csub.git'
package() {
cd $srcdir
msg "Connecting to GIT server...."
if [[ -d $_gitname ]]; then
cd $_gitname || return 1
git pull || return 1
else
git clone $_gitroot || return 1
fi
msg " checkout done."
cd $srcdir/$_gitname || return 1
install -Dm755 v2csub "${pkgdir}/usr/bin/v2csub"
install -Dm744 config "${pkgdir}/etc/v2csub/config"
install -Dm744 defaultkeys "${pkgdir}/etc/v2csub/defaultkeys"
install -Dm744 gfw.json "${pkgdir}/etc/v2csub/gfw.json"
install -Dm744 nonCN.json "${pkgdir}/etc/v2csub/nonCN.json"
install -Dm744 v2csub.service "${pkgdir}/usr/lib/systemd/system/v2csub.service"
for file in $(find templates -type f); do
install -m 644 -D ${file} "${pkgdir}/etc/v2csub/${file}"
done
}
|