[arch-commits] Commit in rime-pinyin-simp/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Sat Mar 14 17:30:50 UTC 2020
Date: Saturday, March 14, 2020 @ 17:30:49
Author: felixonmars
Revision: 597031
archrelease: copy trunk to community-x86_64
Added:
rime-pinyin-simp/repos/community-x86_64/
rime-pinyin-simp/repos/community-x86_64/PKGBUILD
(from rev 597030, rime-pinyin-simp/trunk/PKGBUILD)
----------+
PKGBUILD | 41 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 41 insertions(+)
Copied: rime-pinyin-simp/repos/community-x86_64/PKGBUILD (from rev 597030, rime-pinyin-simp/trunk/PKGBUILD)
===================================================================
--- community-x86_64/PKGBUILD (rev 0)
+++ community-x86_64/PKGBUILD 2020-03-14 17:30:49 UTC (rev 597031)
@@ -0,0 +1,41 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=rime-pinyin-simp
+pkgver=0.0.0.20190120
+_commit=bb5a6dfa871669d2f451b477bfff6d131df6f6c6
+pkgrel=1
+pkgdesc="Simple pinyin input for rime"
+arch=('x86_64')
+url="https://github.com/rime/rime-pinyin-simp"
+license=('LGPL')
+# dependency for reverse lookup
+depends=('rime-stroke')
+makedepends=('librime' 'rime-prelude' 'rime-essay')
+source=("https://github.com/rime/rime-pinyin-simp/archive/$_commit/rime-pinyin-simp-$_commit.tar.gz")
+sha512sums=('9e3572632a013419bd4da72df1526c2ec8633b31db5006a351030b681838582daecdc0e7b6fef3d7802973235dbc2b6dd3c37a5185a664ea847f52363e905d0b')
+
+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