diff options
-rw-r--r-- | .SRCINFO | 19 | ||||
-rw-r--r-- | .gitignore | 3 | ||||
-rw-r--r-- | PKGBUILD | 34 |
3 files changed, 56 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..66a46eb --- /dev/null +++ b/.SRCINFO | |||
@@ -0,0 +1,19 @@ | |||
1 | pkgbase = xq | ||
2 | pkgdesc = xml to json convert parser | ||
3 | pkgver = 0.1 | ||
4 | pkgrel = 1 | ||
5 | url = https://github.com/syui/xq | ||
6 | arch = x86_64 | ||
7 | arch = i686 | ||
8 | license = MIT | ||
9 | noextract = https://github.com/syui/xq/releases/download/0.1/linux_386_xq | ||
10 | noextract = https://github.com/syui/xq/releases/download/0.1/linux_amd64_xq | ||
11 | options = !strip | ||
12 | options = !emptydirs | ||
13 | source = https://github.com/syui/xq/releases/download/0.1/linux_386_xq | ||
14 | source = https://github.com/syui/xq/releases/download/0.1/linux_amd64_xq | ||
15 | sha1sums = ec49fc225d79473b11790e79d7c1c57b3b829cff | ||
16 | sha1sums = 883a2ec0dea0d449b34664367912af289d0b5943 | ||
17 | |||
18 | pkgname = xq | ||
19 | |||
diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c0d838f --- /dev/null +++ b/.gitignore | |||
@@ -0,0 +1,3 @@ | |||
1 | linux_amd64_xq | ||
2 | linux_386_xq | ||
3 | xq | ||
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..3359554 --- /dev/null +++ b/PKGBUILD | |||
@@ -0,0 +1,34 @@ | |||
1 | # Maintainer: syui <syui@users.noreply.github.com> | ||
2 | pkgname=xq | ||
3 | pkgver=0.1 | ||
4 | pkgrel=1 | ||
5 | pkgdesc="xml to json convert parser" | ||
6 | arch=('x86_64' 'i686') | ||
7 | url="https://github.com/syui/xq" | ||
8 | options=('!strip' '!emptydirs') | ||
9 | license=('MIT') | ||
10 | source=("$url/releases/download/$pkgver/linux_386_$pkgname" | ||
11 | "$url/releases/download/$pkgver/linux_amd64_$pkgname") | ||
12 | noextract=(${source[@]%%::*}) | ||
13 | sha1sums=('ec49fc225d79473b11790e79d7c1c57b3b829cff' | ||
14 | '883a2ec0dea0d449b34664367912af289d0b5943') | ||
15 | |||
16 | package() { | ||
17 | mkdir -p ${srcdir}/${pkgname}-${pkgver} | ||
18 | cd "${srcdir}/${pkgname}-${pkgver}" | ||
19 | |||
20 | if [ "`uname -m`" = "x86_64" ];then | ||
21 | mv ../linux_amd64_$pkgname $pkgname | ||
22 | chmod +x $pkgname | ||
23 | fi | ||
24 | |||
25 | if [ "`uname -m`" = "i684" ];then | ||
26 | mv ../linux_386_$pkgname $pkgname | ||
27 | chmod +x $pkgname | ||
28 | fi | ||
29 | |||
30 | install -Dm755 "$pkgname" "$pkgdir/usr/bin/$pkgname" | ||
31 | #sudo install -Dm755 "$pkgdir/usr/bin/$pkgname" /usr/bin | ||
32 | } | ||
33 | |||
34 | # vim:set ts=2 sw=2 et: | ||