[arch-commits] Commit in rime-wubi/repos (community-x86_64 community-x86_64/PKGBUILD)
Felix Yan
felixonmars at archlinux.org
Sat Mar 14 17:34:24 UTC 2020
Date: Saturday, March 14, 2020 @ 17:34:24
Author: felixonmars
Revision: 597033
archrelease: copy trunk to community-x86_64
Added:
rime-wubi/repos/community-x86_64/
rime-wubi/repos/community-x86_64/PKGBUILD
(from rev 597032, rime-wubi/trunk/PKGBUILD)
----------+
PKGBUILD | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
Copied: rime-wubi/repos/community-x86_64/PKGBUILD (from rev 597032, rime-wubi/trunk/PKGBUILD)
===================================================================
--- community-x86_64/PKGBUILD (rev 0)
+++ community-x86_64/PKGBUILD 2020-03-14 17:34:24 UTC (rev 597033)
@@ -0,0 +1,41 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=rime-wubi
+pkgver=0.0.0.20190120
+_commit=dd052ee158a38cb791755318b1aef9b4a3ed0316
+pkgrel=1
+pkgdesc="Wubi input for rime"
+arch=('x86_64')
+url="https://github.com/rime/rime-wubi"
+license=('LGPL')
+# dependency for reverse lookup
+depends=('rime-pinyin-simp')
+makedepends=('librime' 'rime-prelude' 'rime-essay')
+source=("https://github.com/rime/rime-wubi/archive/$_commit/rime-wubi-$_commit.tar.gz")
+sha512sums=('7da0b3ba0fdce2b0f71a07d8f8b6b31986ebd6ebd86ab1fdaeadc0693a39fa7a00b950477e42c51164dcde02617debef3d7db0be97482d7d9402e614dafc1302')
+
+prepare() {
+ cd $pkgname-$_commit
+ # Link essentials
+ for _f in $(pacman -Qql rime-prelude rime-essay | grep -v "/$"); do ln -sf $_f; done
+
+ # Build binaries only for this package
+ rm default.yaml
+ cp /usr/share/rime-data/default.yaml ./
+ sed -i -e '/- schema:/d' -e '/schema_list:/d' default.yaml
+ echo "schema_list:" >> default.yaml
+ ls *.schema.yaml | cut -d "." -f 1 | sed -e 's/\(.*\)/ - schema: \1/' >> default.yaml
+}
+
+build(){
+ cd $pkgname-$_commit
+ rime_deployer --build .
+}
+
+package() {
+ cd $pkgname-$_commit
+ find . -type l -delete
+ rm {,build/}default.yaml user.yaml
+ install -Dm644 *.yaml -t "$pkgdir"/usr/share/rime-data/
+ install -Dm644 build/* -t "$pkgdir"/usr/share/rime-data/build/
+}
More information about the arch-commits
mailing list