GNU bug report logs - #33877
[PATCH] gnu: Add kitty.

Previous Next

Package: guix-patches;

Reported by: Gabriel Hondet <gabrielhondet <at> gmail.com>

Date: Wed, 26 Dec 2018 11:46:02 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 33877 in the body.
You can then email your comments to 33877 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#33877; Package guix-patches. (Wed, 26 Dec 2018 11:46:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Gabriel Hondet <gabrielhondet <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Wed, 26 Dec 2018 11:46:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Gabriel Hondet <gabrielhondet <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: Add kitty.
Date: Wed, 26 Dec 2018 12:41:58 +0100
[Message part 1 (text/plain, inline)]
* gnu/packages/terminals.scm (kitty): New variable.
---
 gnu/packages/terminals.scm | 104 +++++++++++++++++++++++++++++++++++++
 1 file changed, 104 insertions(+)

diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm
index 369e79bf5..223bc3684 100644
--- a/gnu/packages/terminals.scm
+++ b/gnu/packages/terminals.scm
@@ -11,6 +11,7 @@
 ;;; Copyright © 2017 Petter <petter <at> mykolab.ch>
 ;;; Copyright © 2018 Hartmut Goebel <h.goebel <at> crazy-compilers.com>
 ;;; Copyright © 2018 Arun Isaac <arunisaac <at> systemreboot.net>
+;;; Copyright © 2018 Gabriel Hondet <gabrielhondet <at> gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -41,13 +42,16 @@
   #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages check)
+  #:use-module (gnu packages compression)
   #:use-module (gnu packages docbook)
+  #:use-module (gnu packages fontutils)
   #:use-module (gnu packages freedesktop)
   #:use-module (gnu packages gettext)
   #:use-module (gnu packages gl)
   #:use-module (gnu packages glib)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages gtk)
+  #:use-module (gnu packages image)
   #:use-module (gnu packages libevent)
   #:use-module (gnu packages linux)
   #:use-module (gnu packages ncurses)
@@ -900,3 +904,103 @@ per-line fullscreen terminal rendering, and keyboard input event reporting.")
 share your terminal with other users over the Internet.  tmate is a fork of
 tmux.")
     (license license:isc)))
+
+(define-public kitty
+  (package
+    (name "kitty")
+    (version "0.13.1")
+    (home-page "https://sw.kovidgoyal.net/kitty/")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/kovidgoyal/kitty.git")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "1j24zjasdh48z7majfpqr71n1wn5a9688wsmmqn26v8kfb68pqs4"))
+       (modules '((guix build utils)))
+       (snippet
+        '(begin
+           ;; patch needed as sphinx-build is used as a python script
+           ;; whereas the guix package uses a bash script launching the
+           ;; python script
+           (substitute* "docs/conf.py"
+             (("(from kitty.constants import str_version)" kitty-imp)
+              (string-append "sys.path.append(\"..\")\n" kitty-imp)))
+           (substitute* "docs/Makefile"
+             (("^SPHINXBUILD[[:space:]]+= (python3.*)$")
+              "SPHINXBUILD = sphinx-build\n"))))))
+    (build-system gnu-build-system)
+    (inputs
+     `(("python" ,python)
+       ("harfbuzz" ,harfbuzz)
+       ("zlib" ,zlib)
+       ("libpng" ,libpng)
+       ("freetype" ,freetype)
+       ("fontconfig" ,fontconfig)
+       ("pygments" ,python2-pygments)))
+    (native-inputs
+     `(("pkg-config" ,pkg-config)
+       ("libxrandr" ,libxrandr)
+       ("libdbus" ,dbus)
+       ("libxcursor" ,libxcursor)
+       ("libxi" ,libxi)
+       ("libxinerama" ,libxinerama)
+       ("libgl1-mesa" ,mesa)
+       ("libxkbcommon" ,libxkbcommon)
+       ("sphinx" ,python-sphinx)
+       ("ncurses" ,ncurses) ;; for tic command
+       ("wayland-protocols" ,wayland-protocols)))
+    (arguments
+     '(#:phases (modify-phases %standard-phases
+                  (delete 'configure)
+                  (replace 'build
+                    (lambda _
+                      (invoke "python3" "setup.py" "linux-package")))
+                  (replace 'check
+                    (lambda _
+                      (invoke "python3" "setup.py" "test")))
+                  (add-before 'install 'rm-pycache
+                    ;; created python cache __pycache__ are non deterministic
+                    (lambda _
+                      (let ((pycaches (find-files "linux-package/"
+                                                  "__pycache__"
+                                                  #:directories? #t)))
+                        (map delete-file-recursively pycaches))))
+                  (replace 'install
+                    (lambda _
+                      (let* ((out (assoc-ref %outputs "out"))
+                             (obin (string-append out "/bin"))
+                             (olib (string-append out "/lib"))
+                             (oshare (string-append out "/share")))
+                        (begin
+                          (copy-recursively "linux-package/bin" obin)
+                          (copy-recursively "linux-package/share" oshare)
+                          (copy-recursively "linux-package/lib" olib)
+                          #t)))))))
+    (synopsis "Fast, featureful, GPU based terminal emulator")
+    (description "Kitty, the fast, featureful, GPU based terminal emulator
+@itemize @bullet
+@item Offloads rendering to the GPU for lower system load and buttery smooth
+scrolling.  Uses threaded rendering to minimize input latency.
+@item Supports all modern terminal features: graphics (images), unicode,
+true-color, OpenType ligatures, mouse protocol, focus tracking, bracketed
+paste and several new terminal protocol extensions.
+@item Supports tiling multiple terminal windows side by side in different
+layouts without needing to use an extra program like tmux
+@item Can be controlled from scripts or the shell prompt, even over SSH.
+@item Has a framework for Kittens, small terminal programs that can be used to
+extend kitty's functionality.  For example, they are used for Unicode input,
+Hints and Side-by-side diff.
+@item Supports startup sessions which allow you to specify the window/tab
+layout, working directories and programs to run on startup.
+@item Cross-platform: kitty works on Linux and macOS, but because it uses only
+OpenGL for rendering, it should be trivial to port to other Unix-like
+platforms.
+@item Allows you to open the scrollback buffer in a separate window using
+arbitrary programs of your choice.  This is useful for browsing the history
+comfortably in a pager or editor.
+@end itemize")
+    (license license:gpl3+)))
-- 
2.20.1
[signature.asc (application/pgp-signature, inline)]

Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Sun, 06 Jan 2019 20:13:02 GMT) Full text and rfc822 format available.

Notification sent to Gabriel Hondet <gabrielhondet <at> gmail.com>:
bug acknowledged by developer. (Sun, 06 Jan 2019 20:13:03 GMT) Full text and rfc822 format available.

Message #10 received at 33877-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Gabriel Hondet <gabrielhondet <at> gmail.com>
Cc: 33877-done <at> debbugs.gnu.org
Subject: Re: [bug#33877] [PATCH] gnu: Add kitty.
Date: Sun, 06 Jan 2019 21:12:21 +0100
[Message part 1 (text/plain, inline)]
Hello,

Gabriel Hondet <gabrielhondet <at> gmail.com> skribis:

> * gnu/packages/terminals.scm (kitty): New variable.

Applied!  I took the liberty to make the small changes below; let me
know if anything is unclear.

Thanks,
Ludo’.

[Message part 2 (text/x-patch, inline)]
diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm
index 223bc3684c..f6f3845070 100644
--- a/gnu/packages/terminals.scm
+++ b/gnu/packages/terminals.scm
@@ -931,7 +931,8 @@ tmux.")
               (string-append "sys.path.append(\"..\")\n" kitty-imp)))
            (substitute* "docs/Makefile"
              (("^SPHINXBUILD[[:space:]]+= (python3.*)$")
-              "SPHINXBUILD = sphinx-build\n"))))))
+              "SPHINXBUILD = sphinx-build\n"))
+           #t))))
     (build-system gnu-build-system)
     (inputs
      `(("python" ,python)
@@ -968,37 +969,34 @@ tmux.")
                       (let ((pycaches (find-files "linux-package/"
                                                   "__pycache__"
                                                   #:directories? #t)))
-                        (map delete-file-recursively pycaches))))
+                        (for-each delete-file-recursively pycaches)
+                        #t)))
                   (replace 'install
                     (lambda _
                       (let* ((out (assoc-ref %outputs "out"))
                              (obin (string-append out "/bin"))
                              (olib (string-append out "/lib"))
                              (oshare (string-append out "/share")))
-                        (begin
-                          (copy-recursively "linux-package/bin" obin)
-                          (copy-recursively "linux-package/share" oshare)
-                          (copy-recursively "linux-package/lib" olib)
-                          #t)))))))
+                        (copy-recursively "linux-package/bin" obin)
+                        (copy-recursively "linux-package/share" oshare)
+                        (copy-recursively "linux-package/lib" olib)
+                        #t))))))
     (synopsis "Fast, featureful, GPU based terminal emulator")
-    (description "Kitty, the fast, featureful, GPU based terminal emulator
-@itemize @bullet
+    (description "Kitty is a fast and featureful GPU-based terminal emulator:
+@itemize
 @item Offloads rendering to the GPU for lower system load and buttery smooth
 scrolling.  Uses threaded rendering to minimize input latency.
 @item Supports all modern terminal features: graphics (images), unicode,
 true-color, OpenType ligatures, mouse protocol, focus tracking, bracketed
 paste and several new terminal protocol extensions.
 @item Supports tiling multiple terminal windows side by side in different
-layouts without needing to use an extra program like tmux
+layouts without needing to use an extra program like tmux.
 @item Can be controlled from scripts or the shell prompt, even over SSH.
 @item Has a framework for Kittens, small terminal programs that can be used to
 extend kitty's functionality.  For example, they are used for Unicode input,
-Hints and Side-by-side diff.
+hints, and side-by-side diff.
 @item Supports startup sessions which allow you to specify the window/tab
 layout, working directories and programs to run on startup.
-@item Cross-platform: kitty works on Linux and macOS, but because it uses only
-OpenGL for rendering, it should be trivial to port to other Unix-like
-platforms.
 @item Allows you to open the scrollback buffer in a separate window using
 arbitrary programs of your choice.  This is useful for browsing the history
 comfortably in a pager or editor.

bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 04 Feb 2019 12:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 5 years and 54 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.