all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Peng Mei Yu via Guix-patches via <guix-patches@gnu.org>
To: 42230@debbugs.gnu.org
Cc: Peng Mei Yu <i@pengmeiyu.com>
Subject: [bug#42230] [PATCH] gnu: Add emacs-rime.
Date: Mon,  6 Jul 2020 15:38:42 +0800	[thread overview]
Message-ID: <20200706073842.656-1-i@pengmeiyu.com> (raw)

* gnu/packages/emacs-xyz.scm (emacs-rime): New variable.
---
 gnu/packages/emacs-xyz.scm | 49 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 49 insertions(+)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index a67fe06610..76c9056603 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -77,6 +77,7 @@
 ;;; Copyright © 2020 Ryan Desfosses <rdes@protonmail.com>
 ;;; Copyright © 2020 Eric Bavier <bavier@posteo.net>
 ;;; Copyright © 2020 Morgan Smith <Morgan.J.Smith@outlook.com>
+;;; Copyright © 2020 Peng Mei Yu <i@pengmeiyu.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -122,6 +123,7 @@
   #:use-module (gnu packages gtk)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages haskell-apps)
+  #:use-module (gnu packages ibus)
   #:use-module (gnu packages ncurses)
   #:use-module (gnu packages python)
   #:use-module (gnu packages python-xyz)
@@ -23526,3 +23528,50 @@ easily.  Four pre-set options are: @samp{shell}, @samp{terminal},
 @samp{ansi-term}, and @samp{eshell}.  You can also set your custom shell if
 you use some other configuration.")
       (license license:gpl3+))))
+
+(define-public emacs-rime
+  (package
+    (name "emacs-rime")
+    (version "1.0.3")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/DogLooksGood/emacs-rime.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "08rzkiqwcl8j3i2yyibll5lcsj8720plzm9zfdgmxgkw7vhcyix5"))))
+    (build-system emacs-build-system)
+    (arguments
+     '(#:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'patch-rime-data-path
+           (lambda* (#:key inputs #:allow-other-keys)
+             (make-file-writable "rime.el")
+             (emacs-substitute-variables "rime.el"
+               ("rime-share-data-dir"
+                (string-append (assoc-ref inputs "rime-data")
+                               "/share/rime-data")))
+             #t))
+         (add-before 'install 'build-emacs-module
+           (lambda _
+             (invoke "make" "lib")))
+         (add-after 'install 'install-emacs-module
+           (lambda* (#:key outputs #:allow-other-keys)
+             (install-file "librime-emacs.so"
+                           (string-append (assoc-ref outputs "out")
+                                          "/share/emacs/site-lisp"))
+             #t)))))
+    (inputs
+     `(("librime" ,librime)
+       ("rime-data" ,rime-data)))
+    (propagated-inputs
+     `(("emacs-dash" ,emacs-dash)
+       ("emacs-popup" ,emacs-popup)
+       ("emacs-posframe" ,emacs-posframe)))
+    (home-page "https://github.com/DogLooksGood/emacs-rime")
+    (synopsis "Rime input method in Emacs")
+    (description "@dfn{emacs-rime} is an Emacs internal input method built
+upon Rime input method engine.")
+    (license license:gpl3)))
-- 
2.27.0





             reply	other threads:[~2020-07-06 17:34 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-06  7:38 Peng Mei Yu via Guix-patches via [this message]
2020-07-07 12:20 ` [bug#42230] [PATCH] gnu: Add emacs-rime Nicolas Goaziou

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200706073842.656-1-i@pengmeiyu.com \
    --to=guix-patches@gnu.org \
    --cc=42230@debbugs.gnu.org \
    --cc=i@pengmeiyu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.