[arch-commits] Commit in rime-luna-pinyin/repos (2 files)

Felix Yan felixonmars at archlinux.org
Sat Mar 14 12:48:25 UTC 2020


    Date: Saturday, March 14, 2020 @ 12:48:24
  Author: felixonmars
Revision: 596738

archrelease: copy trunk to community-x86_64

Added:
  rime-luna-pinyin/repos/community-x86_64/
  rime-luna-pinyin/repos/community-x86_64/PKGBUILD
    (from rev 596737, rime-luna-pinyin/trunk/PKGBUILD)

----------+
 PKGBUILD |   39 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)

Copied: rime-luna-pinyin/repos/community-x86_64/PKGBUILD (from rev 596737, rime-luna-pinyin/trunk/PKGBUILD)
===================================================================
--- community-x86_64/PKGBUILD	                        (rev 0)
+++ community-x86_64/PKGBUILD	2020-03-14 12:48:24 UTC (rev 596738)
@@ -0,0 +1,39 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=rime-luna-pinyin
+pkgver=0.0.0.20200207
+_commit=ac5c02bd35e6d4d6eed1e1a03f7192919ae649bb
+pkgrel=1
+pkgdesc="Luna pinyin for rime"
+arch=('x86_64')
+url="https://github.com/rime/rime-luna-pinyin"
+license=('LGPL')
+makedepends=('librime' 'rime-prelude' 'rime-essay')
+source=("https://github.com/rime/rime-luna-pinyin/archive/$_commit/rime-luna-pinyin-$_commit.tar.gz")
+sha512sums=('fa85433d2b9cf31f9b98a71528e2cdc3e188cce27a6c14087db0ce77c78b8872d05ed9bf792a142e6e06a0cb293f4abe9bbd51b322071db9da22f77190a68ada')
+
+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