summary refs log tree commit diff
path: root/gnu/packages/rust-apps.scm
diff options
context:
space:
mode:
authorJaeme Sifat <jaeme@runbox.com>2023-10-29 21:16:57 -0400
committerEfraim Flashner <efraim@flashner.co.il>2023-11-28 07:59:28 +0200
commit32aba429d0e8b33fae4384169cad3776bd59a4b3 (patch)
tree029e31d7aa0bde08ba3fc93eef22bf4bfac8da01 /gnu/packages/rust-apps.scm
parentce860cdd87106857f19147529f091592a8937838 (diff)
downloadguix-32aba429d0e8b33fae4384169cad3776bd59a4b3.tar.gz
gnu: Add kibi.
* gnu/packages/rust-apps.scm (kibi): New variable.

Change-Id: Ic2d2a83ffe469091a126ae5b6cc80b703b957db6
Signed-off-by: Efraim Flashner <efraim@flashner.co.il>
Diffstat (limited to 'gnu/packages/rust-apps.scm')
-rw-r--r--gnu/packages/rust-apps.scm45
1 files changed, 45 insertions, 0 deletions
diff --git a/gnu/packages/rust-apps.scm b/gnu/packages/rust-apps.scm
index 25e2634a13..d9335cd507 100644
--- a/gnu/packages/rust-apps.scm
+++ b/gnu/packages/rust-apps.scm
@@ -934,6 +934,51 @@ bar.  It is also compatible with sway.")
 @code{just} is a handy way to save and run project-specific commands.")
     (license license:cc0)))
 
+(define-public kibi
+  (package
+    (name "kibi")
+    (version "0.2.2")
+    (source
+     (origin
+       ;; crates.io doesn't have the config files
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/ilai-deutel/kibi")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1s9ka3pfhpssms2y5707f33n59ljnqqwp7jarh2l55a9dhlnl7d3"))))
+    (build-system cargo-build-system)
+    (arguments
+     (list
+      #:install-source? #f
+      #:cargo-test-flags `(list "--release" "--"
+                                "--skip=syntax::tests::syntax_d_files")
+      #:cargo-inputs `(("rust-libc" ,rust-libc-0.2)
+                       ("rust-unicode-width" ,rust-unicode-width-0.1)
+                       ("rust-winapi" ,rust-winapi-0.3)
+                       ("rust-winapi-util" ,rust-winapi-util-0.1))
+      #:cargo-development-inputs `(("rust-serial-test" ,rust-serial-test-0.5)
+                                   ("rust-tempfile" ,rust-tempfile-3))
+      #:phases #~(modify-phases %standard-phases
+                   (add-after 'install 'install-extras
+                     (lambda* (#:key outputs #:allow-other-keys)
+                       (let* ((out (assoc-ref outputs "out"))
+                              (share (string-append out "/share"))
+                              (syntax.d (string-append share "/syntax.d"))
+                              (etc (string-append out "/etc")))
+                         (mkdir-p syntax.d)
+                         (copy-recursively "syntax.d" syntax.d)
+                         (rename-file "config_example.ini" "config.ini")
+                         (install-file "config.ini" etc)))))))
+    (home-page "https://github.com/ilai-deutel/kibi")
+    (synopsis "Featureful text editor in less than 1024 lines of code")
+    (description
+     "Inspired by the kilo text editor in C, this package provides a text
+editor in less than 1024 lines of code with syntax higlighting, search and
+more.")
+    (license (list license:expat license:asl2.0))))
+
 (define-public maturin
   (package
     (name "maturin")