1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
3 ;;; Copyright © 2014 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2015, 2017 Eric Bavier <bavier@member.fsf.org>
5 ;;; Copyright © 2016, 2017, 2019 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
7 ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
8 ;;; Copyright © 2017, 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
10 ;;; This file is part of GNU Guix.
12 ;;; GNU Guix is free software; you can redistribute it and/or modify it
13 ;;; under the terms of the GNU General Public License as published by
14 ;;; the Free Software Foundation; either version 3 of the License, or (at
15 ;;; your option) any later version.
17 ;;; GNU Guix is distributed in the hope that it will be useful, but
18 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;;; GNU General Public License for more details.
22 ;;; You should have received a copy of the GNU General Public License
23 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
25 (define-module (gnu packages screen)
26 #:use-module (guix licenses)
27 #:use-module (guix packages)
28 #:use-module (guix download)
29 #:use-module (guix git-download)
30 #:use-module (guix build-system gnu)
31 #:use-module (gnu packages)
32 #:use-module (gnu packages ncurses)
33 #:use-module (gnu packages perl)
34 #:use-module (gnu packages python)
35 #:use-module (gnu packages slang)
36 #:use-module (gnu packages texinfo))
44 (uri (string-append "mirror://gnu/screen/screen-"
47 (base32 "0fps0fsipfbh7c2cnp7rjw9n79j0ysq21mk8hzifa33a1r924s8v"))))
48 (build-system gnu-build-system)
50 `(("makeinfo" ,texinfo)))
52 `(("ncurses" ,ncurses)
56 ;; By default, screen supports 16 colors, but we want 256 when
57 ;; ~/.screenrc contains 'term xterm-256color'.
58 '("--enable-colors256")))
59 (home-page "https://www.gnu.org/software/screen/")
60 (synopsis "Full-screen window manager providing multiple terminals")
62 "GNU Screen is a terminal window manager that multiplexes a single
63 terminal between several processes. The virtual terminals each provide
64 features such as a scroll-back buffer and a copy-and-paste mechanism. Screen
65 then manages the different virtual terminals, allowing you to easily switch
66 between them, to detach them from the current session, or even splitting the
67 view to show two terminals at once.")
76 (uri (string-append "mirror://sourceforge/" name "/" name "/"
77 version "/" name "-" version ".tar.gz"))
80 "1wwj2hlngi8qn2pisvhyfxxs8gyqjlgrrv5lz91w8ly54dlzvs9j"))))
81 (build-system gnu-build-system)
85 (modify-phases %standard-phases
87 (lambda* (#:key outputs #:allow-other-keys)
88 (let ((out (assoc-ref outputs "out")))
89 (install-file "dtach" (string-append out "/bin"))
90 (install-file "dtach.1" (string-append out "/share/man/man1"))
94 (home-page "http://dtach.sourceforge.net/")
95 (synopsis "Emulates the detach feature of screen")
97 "dtach is a tiny program that emulates the detach feature of screen,
98 allowing you to run a program in an environment that is protected from the
99 controlling terminal and attach to it later.")
109 (uri (string-append "https://launchpad.net/byobu/trunk/"
110 version "/+download/byobu_"
111 version ".orig.tar.gz"))
114 "0fznlj454vgxgzfw3avmvvjpawggs66da5l8k6v0lnzzd75wgbsb"))
115 (patches (search-patches "byobu-writable-status.patch"))))
116 (build-system gnu-build-system)
118 `(("python" ,python-wrapper) ; for config and session GUIs
119 ("python-newt" ,newt "python")))
122 (modify-phases %standard-phases
124 'configure 'provide-locale
125 (lambda* (#:key inputs #:allow-other-keys)
126 (let ((libc (assoc-ref inputs "libc"))) ; implicit input
127 (substitute* "usr/bin/byobu.in"
128 (("locale") (string-append libc "/bin/locale")))
131 'install 'wrap-python-scripts
132 (lambda* (#:key inputs outputs #:allow-other-keys)
133 (let* ((python (string-append (assoc-ref inputs "python")
135 (out (assoc-ref outputs "out"))
136 (config (string-append out "/bin/byobu-config"))
137 (select (string-append out "/bin/byobu-select-session")))
139 `("BYOBU_PYTHON" = (,python))
140 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
142 `("BYOBU_PYTHON" = (,python)))
144 (home-page "https://byobu.org/")
145 (synopsis "Text-based window manager and terminal multiplexer")
147 "Byobu is a Japanese term for decorative, multi-panel screens that serve
148 as folding room dividers. The Byobu software includes an enhanced profile,
149 configuration utilities, and system status notifications for the GNU Screen
150 window manager as well as the Tmux terminal multiplexer.")
153 (define-public reptyr
161 (url "https://github.com/nelhage/reptyr.git")
162 (commit (string-append "reptyr-" version))))
163 (file-name (git-file-name name version))
165 (base32 "1hnijfz1ab34j2h2cxc3f43rmbclyihgn9x9wxa7jqqgb2xm71hj"))))
166 (build-system gnu-build-system)
168 '(#:tests? #f ; no tests
171 (string-append "PREFIX=" (assoc-ref %outputs "out"))
172 (string-append "BASHCOMPDIR=" (assoc-ref %outputs "out")
173 "/etc/bash_completion.d"))
175 (modify-phases %standard-phases
176 (delete 'configure)))) ; no configure script
177 (home-page "https://github.com/nelhage/reptyr")
178 (synopsis "Tool for reparenting a running program to a new terminal")
180 "reptyr is a utility for taking an existing running program and attaching
181 it to a new terminal. Started a long-running process over @code{ssh}, but have
182 to leave and don't want to interrupt it? Just start a @code{screen}, use
183 reptyr to grab it, and then kill the @code{ssh} session and head on home.")
184 ;; Reptyr currently does not support mips.
185 (supported-systems (delete "mips64el-linux" %supported-systems))