Commit | Line | Data |
---|---|---|
a2c1dcea JMSG |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2016 José Miguel Sánchez García <jmi2k@openmailbox.org> | |
5613ea79 | 3 | ;;; Copyright © 2016 Carlo Zancanaro <carlo@zancanaro.id.au> |
89d3869b | 4 | ;;; Copyright © 2017, 2018, 2020 Eric Bavier <bavier@posteo.net> |
0bf11648 | 5 | ;;; Copyright © 2017 Feng Shu <tumashu@163.com> |
3c986a7d | 6 | ;;; Copyright © 2017 Nikita <nikita@n0.is> |
bcd757fd | 7 | ;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.org> |
f5c9e76f | 8 | ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr> |
2238211a | 9 | ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il> |
75a137da | 10 | ;;; Copyright © 2019 Andreas Enge <andreas@enge.fr> |
c207a8ac | 11 | ;;; Copyright © 2019, 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr> |
28264388 | 12 | ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com> |
8b95f741 | 13 | ;;; Copyright © 2020 Tom Zander <tomz@freedommail.ch> |
e530fb41 | 14 | ;;; Copyright © 2020 Mark Meyer <mark@ofosos.org> |
d5909136 | 15 | ;;; Copyright © 2020 Maxime Devos <maximedevos@telenet.be> |
fce47b75 | 16 | ;;; Copyright © 2021 aecepoglu <aecepoglu@fastmail.fm> |
a2c1dcea JMSG |
17 | ;;; |
18 | ;;; This file is part of GNU Guix. | |
19 | ;;; | |
20 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
21 | ;;; under the terms of the GNU General Public License as published by | |
22 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
23 | ;;; your option) any later version. | |
24 | ;;; | |
25 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
26 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
27 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
28 | ;;; GNU General Public License for more details. | |
29 | ;;; | |
30 | ;;; You should have received a copy of the GNU General Public License | |
31 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
32 | ||
33 | (define-module (gnu packages text-editors) | |
34 | #:use-module (guix packages) | |
35 | #:use-module (guix download) | |
5613ea79 | 36 | #:use-module (guix git-download) |
a2c1dcea | 37 | #:use-module (guix utils) |
fce47b75 | 38 | #:use-module (guix build-system cargo) |
28264388 | 39 | #:use-module (guix build-system cmake) |
a2c1dcea | 40 | #:use-module (guix build-system gnu) |
4f038621 | 41 | #:use-module (guix build-system glib-or-gtk) |
1fffba66 | 42 | #:use-module (guix build-system python) |
a2c1dcea JMSG |
43 | #:use-module ((guix licenses) #:prefix license:) |
44 | #:use-module (gnu packages) | |
28264388 | 45 | #:use-module (gnu packages aspell) |
3312fda0 | 46 | #:use-module (gnu packages assembly) |
2363ed01 | 47 | #:use-module (gnu packages autotools) |
5613ea79 | 48 | #:use-module (gnu packages boost) |
ef64f9ca | 49 | #:use-module (gnu packages code) |
fce47b75 | 50 | #:use-module (gnu packages crates-io) |
5613ea79 | 51 | #:use-module (gnu packages documentation) |
75a137da | 52 | #:use-module (gnu packages fontutils) |
eaf5df6b | 53 | #:use-module (gnu packages freedesktop) |
5613ea79 | 54 | #:use-module (gnu packages gcc) |
2207d522 | 55 | #:use-module (gnu packages gettext) |
0bf11648 FS |
56 | #:use-module (gnu packages glib) |
57 | #:use-module (gnu packages gtk) | |
75a137da | 58 | #:use-module (gnu packages guile) |
1fffba66 | 59 | #:use-module (gnu packages haskell-xyz) |
bcd757fd | 60 | #:use-module (gnu packages libbsd) |
04918a00 | 61 | #:use-module (gnu packages libreoffice) |
28264388 | 62 | #:use-module (gnu packages llvm) |
a2c1dcea JMSG |
63 | #:use-module (gnu packages lua) |
64 | #:use-module (gnu packages ncurses) | |
2238211a | 65 | #:use-module (gnu packages pcre) |
75a137da | 66 | #:use-module (gnu packages perl) |
0bf11648 | 67 | #:use-module (gnu packages pkg-config) |
75a137da | 68 | #:use-module (gnu packages python) |
e530fb41 | 69 | #:use-module (gnu packages python-web) |
2363ed01 | 70 | #:use-module (gnu packages python-xyz) |
04918a00 | 71 | #:use-module (gnu packages qt) |
852ba10a | 72 | #:use-module (gnu packages regex) |
5613ea79 | 73 | #:use-module (gnu packages ruby) |
264ccbb3 | 74 | #:use-module (gnu packages terminals) |
a78364e9 | 75 | #:use-module (gnu packages texinfo) |
28264388 | 76 | #:use-module (gnu packages version-control) |
fb85b967 NG |
77 | #:use-module (gnu packages xml) |
78 | #:use-module (gnu packages xorg)) | |
a2c1dcea JMSG |
79 | |
80 | (define-public vis | |
81 | (package | |
82 | (name "vis") | |
b6f0c992 | 83 | (version "0.7") ; also update the vis-test input |
d198eca0 TGR |
84 | (source |
85 | (origin | |
86 | (method git-fetch) | |
87 | (uri (git-reference | |
b6f0c992 | 88 | (url "https://git.sr.ht/~martanne/vis") |
d198eca0 TGR |
89 | (commit (string-append "v" version)))) |
90 | (sha256 | |
b6f0c992 | 91 | (base32 "1g05ncsnk57kcqm9wsv6sz8b24kyzj8r5rfpa1wfwj8qkjzx3vji")) |
d198eca0 | 92 | (file-name (git-file-name name version)))) |
a2c1dcea JMSG |
93 | (build-system gnu-build-system) |
94 | (arguments | |
852ba10a | 95 | `(#:test-target "test" |
a2c1dcea JMSG |
96 | #:phases |
97 | (modify-phases %standard-phases | |
37e64053 TGR |
98 | (add-after 'unpack 'unpack-test-suite |
99 | (lambda* (#:key inputs #:allow-other-keys) | |
100 | (let ((vis-test (assoc-ref inputs "vis-test"))) | |
101 | (copy-recursively vis-test "test") | |
102 | #t))) | |
103 | (delete 'check) ; the tests need a wrapped vis | |
a2c1dcea JMSG |
104 | (add-after 'install 'wrap-binary |
105 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
106 | (let* ((out (assoc-ref outputs "out")) | |
107 | (lpeg (assoc-ref inputs "lua-lpeg")) | |
108 | (lua-version ,(version-major+minor (package-version lua))) | |
109 | (LUA_PATH (string-append lpeg "/share/lua/" | |
110 | lua-version "/?.lua")) | |
111 | (LUA_CPATH (string-append lpeg "/lib/lua/" | |
112 | lua-version "/?.so"))) | |
113 | (wrap-program (string-append out "/bin/vis") | |
114 | `("LUA_PATH" ":" prefix (,LUA_PATH)) | |
115 | `("LUA_CPATH" ":" prefix (,LUA_CPATH))) | |
37e64053 TGR |
116 | #t))) |
117 | (add-after 'wrap-binary 'check | |
118 | (assoc-ref %standard-phases 'check)) | |
119 | (add-before 'check 'set-up-tests | |
120 | (lambda* (#:key outputs #:allow-other-keys) | |
121 | (let ((out (assoc-ref outputs "out"))) | |
122 | ;; DEFAULT_COMPILER is hard-coded here. | |
123 | (substitute* "test/core/ccan-config.c" | |
124 | (("\"cc\"") | |
125 | (format #f "\"~a\"" ,(cc-for-target)))) | |
126 | ||
127 | ;; Use the ‘vis’ executable that we wrapped above. | |
128 | (install-file (string-append out "/bin/vis") ".") | |
129 | ||
130 | ;; XXX Delete 2 failing tests. TODO: make them not fail. :-) | |
131 | (for-each delete-file | |
132 | (find-files "test/vis/selections" "^complement")) | |
a2c1dcea | 133 | #t)))))) |
37e64053 TGR |
134 | (native-inputs |
135 | `(("vis-test" | |
136 | ,(origin | |
137 | (method git-fetch) | |
138 | (uri (git-reference | |
b6f0c992 | 139 | (url "https://git.sr.ht/~martanne/vis-test") |
140 | (commit "bbd2f34ff788e87a51a74069069273ad83c44f1f"))) | |
37e64053 | 141 | (sha256 |
b6f0c992 | 142 | (base32 "1jsvg2lg3xqfgi79x08kx94mc34mh62ivca10vsci6fqsk68jbd0")) |
37e64053 | 143 | (file-name (git-file-name "vis-test" version)))))) |
c695fb76 TGR |
144 | (inputs `(("lua" ,lua) |
145 | ("ncurses" ,ncurses) | |
146 | ("libtermkey" ,libtermkey) | |
147 | ("lua-lpeg" ,lua-lpeg) | |
852ba10a | 148 | ("tre" ,tre))) |
a2c1dcea JMSG |
149 | (synopsis "Vim-like text editor") |
150 | (description | |
151 | "Vis aims to be a modern, legacy free, simple yet efficient vim-like text | |
152 | editor. It extends vim's modal editing with built-in support for multiple | |
153 | cursors/selections and combines it with sam's structural regular expression | |
154 | based command language.") | |
155 | (home-page "https://github.com/martanne/vis") | |
156 | (license (list license:isc ; Main distribution. | |
157 | license:public-domain ; map.[ch] | |
158 | license:expat)))) ; lexers and libutf.[ch] | |
5613ea79 CZ |
159 | |
160 | (define-public kakoune | |
fbe8ebec TGR |
161 | (package |
162 | (name "kakoune") | |
ce04a92f | 163 | (version "2020.09.01") |
fbe8ebec TGR |
164 | (source |
165 | (origin | |
166 | (method url-fetch) | |
167 | (uri (string-append "https://github.com/mawww/kakoune/" | |
168 | "releases/download/v" version "/" | |
a1cb6928 | 169 | "kakoune-" version ".tar.bz2")) |
fbe8ebec | 170 | (sha256 |
ce04a92f | 171 | (base32 "0x81rxy7bqnhd9374g5ypy4w4nxmm0vnqw6b52bf62jxdg2qj6l6")))) |
fbe8ebec TGR |
172 | (build-system gnu-build-system) |
173 | (arguments | |
174 | `(#:make-flags | |
175 | (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) | |
176 | #:phases | |
177 | (modify-phases %standard-phases | |
178 | (add-after 'unpack 'patch-source | |
179 | (lambda _ | |
180 | ;; kakoune uses confstr with _CS_PATH to find out where to find | |
181 | ;; a posix shell, but this doesn't work in the build | |
182 | ;; environment. This substitution just replaces that result | |
183 | ;; with the "sh" path. | |
184 | (substitute* "src/shell_manager.cc" | |
185 | (("if \\(m_shell.empty\\(\\)\\)" line) | |
186 | (string-append "m_shell = \"" (which "sh") | |
187 | "\";\n " line))) | |
188 | #t)) | |
189 | (delete 'configure) ; no configure script | |
1c63b397 | 190 | ;; kakoune requires us to be in the src/ directory to build. |
fbe8ebec TGR |
191 | (add-before 'build 'chdir |
192 | (lambda _ (chdir "src") #t))))) | |
193 | (native-inputs | |
194 | `(("asciidoc" ,asciidoc) | |
195 | ("pkg-config" ,pkg-config) | |
196 | ("ruby" ,ruby))) | |
197 | (inputs | |
73eacca8 | 198 | `(("ncurses" ,ncurses))) |
fbe8ebec TGR |
199 | (synopsis "Vim-inspired code editor") |
200 | (description | |
201 | "Kakoune is a code editor heavily inspired by Vim, as such most of its | |
5613ea79 CZ |
202 | commands are similar to Vi's ones, and it shares Vi's \"keystrokes as a text |
203 | editing language\" model. Kakoune has a strong focus on interactivity, most | |
204 | commands provide immediate and incremental results, while still being | |
205 | competitive (as in keystroke count) with Vim.") | |
27405497 | 206 | (home-page "https://kakoune.org/") |
fbe8ebec | 207 | (license license:unlicense))) |
f255a6db | 208 | |
fce47b75 | 209 | (define-public kak-lsp |
210 | (package | |
211 | (name "kak-lsp") | |
212 | (version "9.0.0") | |
213 | (source | |
214 | (origin | |
215 | (method git-fetch) | |
216 | (uri (git-reference | |
217 | (url "https://github.com/kak-lsp/kak-lsp") | |
218 | (commit (string-append "v" version)))) | |
219 | (file-name (git-file-name name version)) | |
220 | (sha256 "1wfv2fy5ga6kc51zka3pak0hq97csm2l11bz74w3n1hrf5q9nnf8"))) | |
221 | (build-system cargo-build-system) | |
222 | (arguments | |
223 | `(#:cargo-inputs | |
224 | (("rust-crossbeam-channel" ,rust-crossbeam-channel-0.4) | |
225 | ("rust-clap" ,rust-clap-2) | |
226 | ("rust-daemonize" ,rust-daemonize-0.4) | |
227 | ("rust-dirs" ,rust-dirs-2) | |
228 | ("rust-enum_primitive" ,rust-enum-primitive-0.1) | |
229 | ("rust-glob" ,rust-glob-0.3) | |
230 | ("rust-itertools" ,rust-itertools-0.9) | |
231 | ("rust-lsp-types" ,rust-lsp-types-0.80) | |
232 | ("rust-jsonrpc-core" ,rust-jsonrpc-core-14) | |
233 | ("rust-libc" ,rust-libc-0.2) | |
234 | ("rust-rand" ,rust-rand-0.7) | |
235 | ("rust-regex" ,rust-regex-1) | |
236 | ("rust-ropey" ,rust-ropey-1) | |
237 | ("rust-serde" ,rust-serde-1) | |
238 | ("rust-serde_derive" ,rust-serde-derive-1) | |
239 | ("rust-serde_json" ,rust-serde-json-1) | |
240 | ("rust-slog" ,rust-slog-2) | |
241 | ("rust-slog-scope" ,rust-slog-scope-4) | |
242 | ("rust-sloggers" ,rust-sloggers-1) | |
243 | ("rust-toml" ,rust-toml-0.5) | |
244 | ("rust-url" ,rust-url-2) | |
245 | ("rust-whoami" ,rust-whoami-0.8)))) | |
246 | (home-page "https://github.com/kak-lsp/kak-lsp") | |
247 | (synopsis "Language Server Protocol (LSP) client for Kakoune") | |
248 | (description | |
249 | "kak-lsp is a Language Server Protocol client for Kakoune implemented in | |
250 | Rust.") | |
251 | (license license:unlicense))) | |
252 | ||
f255a6db EB |
253 | (define-public joe |
254 | (package | |
255 | (name "joe") | |
bc111d39 | 256 | (version "4.6") |
f255a6db EB |
257 | (source |
258 | (origin | |
259 | (method url-fetch) | |
260 | (uri (string-append "https://sourceforge.net/projects/joe-editor/" | |
261 | "files/JOE sources/joe-" version "/" | |
262 | "joe-" version ".tar.gz")) | |
263 | (sha256 | |
264 | (base32 | |
bc111d39 | 265 | "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9")))) |
f255a6db EB |
266 | (build-system gnu-build-system) |
267 | (inputs `(("ncurses" ,ncurses))) | |
268 | (home-page "http://joe-editor.sourceforge.net/") | |
269 | (synopsis "Console screen editor") | |
270 | (description | |
7904f18a EB |
271 | "JOE is a powerful console screen editor with a \"mode-less\" user |
272 | interface similar to many user-friendly editors. JOE has some of the key | |
273 | bindings and many of the powerful features of GNU Emacs.") | |
f255a6db | 274 | (license license:gpl3+))) |
0bf11648 | 275 | |
28264388 MB |
276 | (define-public jucipp |
277 | (package | |
278 | (name "jucipp") | |
5a29639c | 279 | (version "1.6.3") |
28264388 MB |
280 | (home-page "https://gitlab.com/cppit/jucipp") |
281 | (source (origin | |
282 | (method git-fetch) | |
283 | (uri (git-reference (url home-page) | |
284 | (commit (string-append "v" version)) | |
285 | ;; Two submodules are required which are | |
286 | ;; developed alongside JuCi++ and difficult | |
287 | ;; to package separately. | |
288 | (recursive? #t))) | |
289 | (file-name (git-file-name name version)) | |
290 | (sha256 | |
5a29639c | 291 | (base32 "1gy2xb5rm7q4zx9rl23h96b1i46fz27v25nklj50fvqp8ax2gxqy")))) |
28264388 MB |
292 | (build-system cmake-build-system) |
293 | (arguments | |
294 | `(#:configure-flags '("-DBUILD_TESTING=ON" | |
295 | ||
296 | ;; These arguments are here to facilitate an "in-source" | |
297 | ;; build using "./build" instead of the default "../build". | |
298 | ;; The test suite expects that to be the case. | |
299 | "..") | |
300 | #:out-of-source? #f | |
301 | #:phases (modify-phases %standard-phases | |
302 | (add-before 'configure 'enter-build-directory | |
303 | (lambda _ | |
304 | (mkdir "build") | |
305 | (chdir "build") | |
306 | #t)) | |
307 | ||
28264388 MB |
308 | (add-after 'unpack 'patch-tiny-process-library |
309 | (lambda _ | |
310 | (with-directory-excursion "lib/tiny-process-library" | |
311 | (substitute* '("process_unix.cpp" | |
312 | "tests/io_test.cpp") | |
313 | (("/bin/sh") (which "sh")))) | |
314 | #t)) | |
315 | (add-after 'unpack 'disable-git-test | |
316 | (lambda _ | |
317 | (substitute* "tests/CMakeLists.txt" | |
318 | ;; Disable the git test, as it requires the full checkout. | |
319 | (("add_test\\(git_test.*\\)") "")) | |
320 | #t)) | |
321 | (add-before 'check 'pre-check | |
322 | (lambda* (#:key inputs #:allow-other-keys) | |
323 | ;; Tests do not expect HOME to be empty. | |
324 | (setenv "HOME" "/etc") | |
325 | ||
326 | ;; Most tests require an X server. | |
327 | (let ((xorg-server (assoc-ref inputs "xorg-server")) | |
328 | (display ":1")) | |
329 | (setenv "DISPLAY" display) | |
330 | (system (string-append xorg-server "/bin/Xvfb " | |
331 | display " &"))) | |
7e9544c3 MB |
332 | #t)) |
333 | (add-after 'install 'wrap | |
334 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
335 | ;; The package needs GTK+ and GtkSourceView on XDG_DATA_DIRS | |
336 | ;; for syntax highlighting to work. shared-mime-info is | |
337 | ;; necessary for MIME handling. | |
338 | ;; XXX: Ideally we'd reuse glib-or-gtk-wrap here, but it | |
339 | ;; does not pick up $gtksourceview/share/gtksourceview-3.0. | |
340 | (let ((out (assoc-ref outputs "out")) | |
341 | (gtk+ (assoc-ref inputs "gtk+")) | |
342 | (gtksourceview (assoc-ref inputs "gtksourceview")) | |
343 | (shared-mime-info (assoc-ref inputs "shared-mime-info"))) | |
344 | (wrap-program (string-append out "/bin/juci") | |
345 | `("XDG_DATA_DIRS" ":" prefix | |
346 | (,(string-join | |
347 | (map (lambda (pkg) | |
348 | (string-append pkg "/share")) | |
349 | (list out gtk+ gtksourceview shared-mime-info)) | |
350 | ":")))) | |
351 | #t)))))) | |
28264388 MB |
352 | (native-inputs |
353 | `(("pkg-config" ,pkg-config) | |
354 | ("xorg-server" ,xorg-server-for-tests))) | |
355 | (inputs | |
356 | `(("aspell" ,aspell) | |
357 | ("boost" ,boost) | |
ef64f9ca | 358 | ("ctags" ,universal-ctags) |
28264388 MB |
359 | ("gtkmm" ,gtkmm) |
360 | ("gtksourceviewmm" ,gtksourceviewmm) | |
0dd7f868 | 361 | ("libclang" ,clang-11) ;XXX: must be the same version as Mesas LLVM |
28264388 MB |
362 | ("libgit2" ,libgit2))) |
363 | (synopsis "Lightweight C++ IDE") | |
364 | (description | |
78d1f6dc | 365 | "juCi++ is a small @acronym{IDE, Integrated Development Environment} |
28264388 MB |
366 | designed especially towards libclang with speed, stability, and ease of use |
367 | in mind. | |
368 | ||
369 | It supports autocompletion, on-the-fly warnings and errors, syntax | |
370 | highlighting, and integrates with Git as well as the CMake and Meson build | |
371 | systems.") | |
372 | (license license:expat))) | |
373 | ||
0bf11648 FS |
374 | (define-public leafpad |
375 | (package | |
376 | (name "leafpad") | |
377 | (version "0.8.18.1") | |
378 | (source (origin | |
379 | (method url-fetch) | |
b7fd77ef | 380 | (uri (string-append "mirror://savannah/" |
0bf11648 FS |
381 | "leafpad/leafpad-" version ".tar.gz")) |
382 | (sha256 | |
383 | (base32 | |
384 | "0b0az2wvqgvam7w0ns1j8xp2llslm1rx6h7zcsy06a7j0yp257cm")))) | |
4f038621 | 385 | (build-system glib-or-gtk-build-system) |
0bf11648 FS |
386 | (native-inputs |
387 | `(("intltool" ,intltool) | |
388 | ("pkg-config" ,pkg-config))) | |
389 | (inputs | |
390 | `(("gtk+" ,gtk+-2))) | |
dde5831c | 391 | (home-page "http://tarot.freeshell.org/leafpad/") |
0bf11648 FS |
392 | (synopsis "GTK+ based text editor") |
393 | (description "Leafpad is a GTK+ text editor that emphasizes simplicity. As | |
394 | development focuses on keeping weight down to a minimum, only the most essential | |
395 | features are implemented in the editor. Leafpad is simple to use, is easily | |
396 | compiled, requires few libraries, and starts up quickly. ") | |
397 | (license license:gpl2+))) | |
3312fda0 | 398 | |
399 | (define-public e3 | |
400 | (package | |
401 | (name "e3") | |
402 | (version "2.82") | |
403 | (source (origin | |
404 | (method url-fetch) | |
405 | (uri (string-append "https://sites.google.com/site/e3editor/Home/" | |
406 | "e3-" version ".tgz")) | |
407 | (sha256 | |
408 | (base32 | |
409 | "0919kadkas020maqq37852isnzp053q2fnws2zh3mz81d1jiviak")) | |
410 | (modules '((guix build utils))) | |
411 | ||
412 | ;; Remove pre-built binaries. | |
6cbee49d MW |
413 | (snippet '(begin |
414 | (delete-file-recursively "bin") | |
415 | #t)))) | |
3312fda0 | 416 | (build-system gnu-build-system) |
417 | (arguments | |
418 | `(#:tests? #f | |
419 | #:make-flags (list (string-append "PREFIX=" | |
420 | (assoc-ref %outputs "out"))) | |
421 | #:phases (modify-phases %standard-phases | |
422 | (delete 'configure)))) | |
423 | (native-inputs | |
424 | `(("nasm" ,nasm))) | |
425 | (home-page "https://sites.google.com/site/e3editor/") | |
426 | (synopsis "Tiny text editor written in assembly") | |
427 | (description | |
428 | "e3 is a micro text editor with an executable code size between 3800 and | |
429 | 35000 bytes. Except for ``syntax highlighting'', the e3 binary supports all | |
430 | of the basic functions one expects plus built in arithmetic calculations. | |
431 | UTF-8 coding of unicode characters is supported as well. e3 can use | |
432 | Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings. e3 can be used on | |
433 | 16, 32, and 64-bit CPUs.") | |
434 | (supported-systems '("x86_64-linux" "i686-linux")) | |
435 | (license license:gpl2+))) | |
bcd757fd LC |
436 | |
437 | (define-public mg | |
438 | (package | |
439 | (name "mg") | |
77100119 | 440 | (version "20180927") |
bcd757fd | 441 | (source (origin |
a4d8b386 TGR |
442 | (method git-fetch) |
443 | (uri (git-reference | |
444 | (url "https://github.com/hboetes/mg") | |
445 | (commit version))) | |
446 | (file-name (git-file-name name version)) | |
bcd757fd LC |
447 | (sha256 |
448 | (base32 | |
77100119 | 449 | "14vrm8lvwksf697sqks7xfd1xaqjlqjc9afjk33sksq5p27wr203")) |
bcd757fd | 450 | (modules '((guix build utils))) |
6cbee49d MW |
451 | (snippet '(begin |
452 | (substitute* "GNUmakefile" | |
453 | (("/usr/bin/") "")) | |
454 | #t)))) | |
bcd757fd LC |
455 | (build-system gnu-build-system) |
456 | (native-inputs | |
457 | `(("pkg-config" ,pkg-config))) | |
458 | (inputs | |
459 | `(("libbsd" ,libbsd) | |
460 | ("ncurses" ,ncurses))) | |
461 | (arguments | |
462 | ;; No test suite available. | |
463 | '(#:tests? #f | |
464 | #:make-flags (list (string-append "prefix=" %output) | |
bcd757fd LC |
465 | "CC=gcc") |
466 | #:phases (modify-phases %standard-phases | |
a4d8b386 | 467 | (delete 'configure) ; no configure script |
217ce570 | 468 | (add-before 'build 'correct-location-of-difftool |
469 | (lambda _ | |
470 | (substitute* "buffer.c" | |
471 | (("/usr/bin/diff") | |
472 | (which "diff"))) | |
473 | #t)) | |
bcd757fd LC |
474 | (add-before 'install 'patch-tutorial-location |
475 | (lambda* (#:key outputs #:allow-other-keys) | |
476 | (substitute* "mg.1" | |
477 | (("/usr") (assoc-ref outputs "out"))) | |
478 | #t)) | |
479 | (add-after 'install 'install-tutorial | |
480 | (lambda* (#:key outputs #:allow-other-keys) | |
481 | (let* ((out (assoc-ref outputs "out")) | |
482 | (doc (string-append out "/share/doc/mg"))) | |
483 | (install-file "tutorial" doc) | |
484 | #t)))))) | |
c3d82885 | 485 | (home-page "https://homepage.boetes.org/software/mg/") |
bcd757fd LC |
486 | (synopsis "Microscopic GNU Emacs clone") |
487 | (description | |
16fcca64 TGR |
488 | "Mg (@command{mg}) is a GNU Emacs style editor, with which it is |
489 | \"broadly\" compatible. This is a portable version of the mg maintained by the | |
490 | OpenBSD team.") | |
bcd757fd | 491 | (license license:public-domain))) |
04918a00 | 492 | |
3fad9a69 NG |
493 | (define-public qemacs |
494 | (package | |
495 | (name "qemacs") | |
496 | (version "0.3.3") | |
497 | (source | |
498 | (origin | |
499 | (method url-fetch) | |
500 | (uri (string-append "https://bellard.org/qemacs/" | |
501 | "qemacs-" version ".tar.gz")) | |
502 | (sha256 | |
503 | (base32 "156z4wpj49i6j388yjird5qvrph7hz0grb4r44l4jf3q8imadyrg")))) | |
504 | (build-system gnu-build-system) | |
505 | (arguments | |
506 | `(#:tests? #f ;no test | |
507 | #:phases | |
508 | (modify-phases %standard-phases | |
509 | (add-before 'build 'build-qhtml | |
510 | ;; Build fails without first creating qHTML library. | |
511 | (lambda _ (invoke "make" "-C" "libqhtml"))) | |
512 | (add-before 'install 'fix-man-pages-directory | |
513 | ;; Install in $out/share/man instead of $out/man. | |
514 | (lambda _ | |
515 | (substitute* "Makefile" | |
516 | (("/man/man1" all) (string-append "/share" all))) | |
517 | #t)) | |
518 | (add-before 'install 'create-directories | |
519 | ;; Ensure directories exist before installing files. | |
520 | (lambda* (#:key outputs #:allow-other-keys) | |
521 | (let ((out (assoc-ref outputs "out"))) | |
522 | (for-each (lambda (d) (mkdir-p (string-append out d))) | |
523 | '("/bin" "/share/man/man1" "/share/qe")) | |
524 | #t))) | |
525 | (add-after 'install 'install-extra-documentation | |
526 | ;; Install sample configuration file, Info, and HTML manual. | |
527 | (lambda* (#:key outputs #:allow-other-keys) | |
528 | (let* ((share (string-append (assoc-ref outputs "out") "/share")) | |
529 | (doc (string-append share "/doc/" ,name "-" ,version)) | |
530 | (html (string-append share "/html")) | |
531 | (info (string-append share "/info")) | |
532 | (makeinfo (string-append (assoc-ref %build-inputs "texinfo") | |
533 | "/bin/makeinfo"))) | |
534 | ;; First fix Texinfo documentation, create appropriate | |
535 | ;; directories, then generate Info and HTML files there. | |
536 | (substitute* "qe-doc.texi" | |
537 | (("^M-([{}])" _ bracket) (string-append "M-@" bracket))) | |
538 | (for-each (lambda (d) (mkdir-p d)) (list html info)) | |
539 | (invoke makeinfo "qe-doc.texi" "-o" info) | |
540 | (invoke makeinfo "qe-doc.texi" "--html" "--no-split" "-o" html) | |
541 | ;; Install sample configuration file. | |
542 | (install-file "config.eg" doc) | |
543 | #t)))))) | |
544 | (native-inputs | |
545 | `(("texinfo" ,texinfo))) | |
546 | (inputs | |
547 | `(("libx11" ,libx11) | |
548 | ("libxext" ,libxext) | |
549 | ("libxv" ,libxv))) | |
550 | (home-page "https://bellard.org/qemacs/") | |
551 | (synopsis "Small but powerful text editor") | |
552 | (description "QEmacs (for Quick Emacs) is a very small but | |
553 | powerful editor. It has features that even big editors lack: | |
554 | ||
555 | @itemize | |
556 | ||
557 | @item Full screen editor with an Emacs look and feel with all Emacs | |
558 | common features: multi-buffer, multi-window, command mode, universal | |
559 | argument, keyboard macros, config file with C-like syntax, minibuffer | |
560 | with completion and history. | |
561 | ||
562 | @item Can edit files of hundreds of Megabytes without being slow by | |
563 | using a highly optimized internal representation and by mmaping the | |
564 | file. | |
565 | ||
566 | @item Full Unicode support, including multi charset handling (8859-x, | |
567 | UTF8, SJIS, EUC-JP, ...) and bidirectional editing respecting the | |
568 | Unicode bidi algorithm. Arabic and Indic scripts handling (in | |
569 | progress). | |
570 | ||
571 | @item WYSIWYG HTML/XML/CSS2 mode graphical editing. Also supports | |
572 | Lynx like rendering on VT100 terminals. | |
573 | ||
574 | @item WYSIWYG DocBook mode based on XML/CSS2 renderer. | |
575 | ||
576 | @item C mode: coloring with immediate update. Emacs like auto-indent. | |
577 | ||
578 | @item Shell mode: colorized VT100 emulation so that your shell work | |
579 | exactly as you expect. Compile mode with next/prev error. | |
580 | ||
581 | @item Input methods for most languages, including Chinese (input | |
582 | methods come from the Yudit editor). | |
583 | ||
584 | @item Hexadecimal editing mode with insertion and block commands. | |
585 | Unicode hexa editing is also supported. | |
586 | ||
587 | @item Works on any VT100 terminals without termcap. UTF8 VT100 | |
588 | support included with double width glyphs. | |
589 | ||
590 | @item X11 support. Support multiple proportional fonts at the same | |
591 | time (as XEmacs). X Input methods supported. Xft extension supported | |
592 | for anti aliased font display. | |
593 | ||
594 | @item Small! Full version (including HTML/XML/CSS2/DocBook rendering | |
595 | and all charsets): 200KB big. Basic version (without bidir/unicode | |
596 | scripts/input/X11/C/Shell/HTML/Dired): 49KB. | |
597 | @end itemize") | |
598 | (license license:lgpl2.1+))) | |
599 | ||
04918a00 EB |
600 | (define-public ghostwriter |
601 | (package | |
602 | (name "ghostwriter") | |
61361ef2 LF |
603 | ;; XXX We use a release candidate to fix incompatibility with Qt 5.15. |
604 | (version "2.0.0-rc4") | |
04918a00 EB |
605 | (source (origin |
606 | (method git-fetch) | |
607 | (uri (git-reference | |
b0e7b699 | 608 | (url "https://github.com/wereturtle/ghostwriter") |
61361ef2 | 609 | (commit version))) |
04918a00 EB |
610 | (file-name (git-file-name name version)) |
611 | (sha256 | |
612 | (base32 | |
61361ef2 | 613 | "07547503a209hc0fcg902w3x0s1m899c10nj3gqz3hak0cmrasi3")))) |
04918a00 EB |
614 | (build-system gnu-build-system) |
615 | (native-inputs | |
616 | `(("pkg-config" ,pkg-config) | |
58ab7f29 | 617 | ("qttools" ,qttools))) ; for lrelease |
04918a00 EB |
618 | (inputs |
619 | `(("hunspell" ,hunspell) | |
620 | ("qtbase" ,qtbase) | |
89d3869b | 621 | ("qtdeclarative" ,qtdeclarative) |
04918a00 | 622 | ("qtmultimedia" ,qtmultimedia) |
89d3869b | 623 | ("qtquickcontrols" ,qtquickcontrols) |
04918a00 | 624 | ("qtsvg" ,qtsvg) |
89d3869b EB |
625 | ("qtwebchannel" ,qtwebchannel))) |
626 | (propagated-inputs ; To get native-search-path | |
627 | `(("qtwebengine" ,qtwebengine))) | |
04918a00 EB |
628 | (arguments |
629 | `(#:phases | |
630 | (modify-phases %standard-phases | |
631 | (replace 'configure | |
632 | (lambda* (#:key outputs #:allow-other-keys) | |
633 | (let ((out (assoc-ref outputs "out"))) | |
634 | (invoke "qmake" (string-append "PREFIX=" out))))) | |
635 | (add-after 'configure 'create-translations | |
636 | (lambda _ | |
637 | ;; `lrelease` will not overwrite, so delete existing .qm files | |
638 | (for-each delete-file (find-files "translations" ".*\\.qm")) | |
639 | (apply invoke "lrelease" (find-files "translations" ".*\\.ts")))) | |
640 | ;; Ensure that icons are found at runtime. | |
641 | (add-after 'install 'wrap-executable | |
642 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
643 | (let ((out (assoc-ref outputs "out"))) | |
644 | (wrap-program (string-append out "/bin/ghostwriter") | |
645 | `("QT_PLUGIN_PATH" ":" prefix | |
646 | ,(map (lambda (label) | |
647 | (string-append (assoc-ref inputs label) | |
648 | "/lib/qt5/plugins/")) | |
649 | '("qtsvg" "qtmultimedia")))))))))) | |
650 | (home-page "https://wereturtle.github.io/ghostwriter/") | |
651 | (synopsis "Write without distractions") | |
652 | (description | |
653 | "@code{ghostwriter} provides a relaxing, distraction-free writing | |
654 | environment with Markdown markup.") | |
58ab7f29 | 655 | (license license:gpl3+))) ; icons/* under CC-BY-SA3 |
2238211a | 656 | |
1fffba66 NG |
657 | (define-public manuskript |
658 | (package | |
659 | (name "manuskript") | |
d5a08205 | 660 | (version "0.11.0") |
1fffba66 NG |
661 | (source |
662 | (origin | |
663 | (method git-fetch) | |
664 | (uri (git-reference | |
b0e7b699 | 665 | (url "https://github.com/olivierkes/manuskript") |
1fffba66 NG |
666 | (commit version))) |
667 | (file-name (git-file-name name version)) | |
668 | (sha256 | |
d5a08205 | 669 | (base32 "1l6l9k6k69yv8xqpll0zv9cwdqqg4zvxy90l6sx5nv2yywh5crla")))) |
1fffba66 NG |
670 | (build-system python-build-system) |
671 | (arguments | |
672 | `(#:tests? #f ;no test | |
673 | #:phases | |
674 | (modify-phases %standard-phases | |
675 | (delete 'configure) | |
676 | (delete 'build) | |
677 | (replace 'install | |
678 | (lambda* (#:key outputs #:allow-other-keys) | |
679 | (let* ((out (assoc-ref outputs "out")) | |
680 | (share (string-append out "/share/manuskript"))) | |
681 | ;; Install data. | |
682 | (mkdir-p share) | |
683 | (for-each | |
684 | (lambda (d) | |
685 | (let ((destination (string-append share "/" d))) | |
686 | (mkdir-p destination) | |
687 | (copy-recursively d destination))) | |
688 | '("bin" "i18n" "icons" "libs" "manuskript" "resources")) | |
689 | ;; Install documentation. | |
690 | (let ((doc (string-append out | |
691 | "/doc/manuskript-" ,version | |
692 | "/sample-projects"))) | |
693 | (mkdir-p doc) | |
694 | (copy-recursively "sample-projects" doc)) | |
695 | ;; Wrap executable in "$out/share/manuskript/bin" and | |
696 | ;; link to it from "$out/bin". | |
697 | (let ((bin (string-append out "/bin")) | |
698 | (executable (string-append share "/bin/manuskript"))) | |
699 | (wrap-program executable | |
700 | (list "PYTHONPATH" 'prefix (list (getenv "PYTHONPATH")))) | |
701 | (mkdir-p bin) | |
702 | (with-directory-excursion bin | |
703 | (symlink (string-append share "/bin/manuskript") | |
704 | "manuskript"))) | |
705 | ;; Install icons and create .desktop file. | |
706 | (let ((apps (string-append out "/share/applications")) | |
707 | (icons-dir (string-append out "/share/pixmaps"))) | |
708 | (install-file "icons/Manuskript/manuskript.svg" icons-dir) | |
709 | (mkdir-p apps) | |
6bf5f207 EF |
710 | (make-desktop-entry-file (string-append apps "/manuskript.desktop") |
711 | #:name "Manuskript" | |
712 | #:mime-type "application/x-manuskript-book;" | |
713 | #:exec (string-append out "/bin/manuskript %f") | |
714 | #:comment '((#f "Tool for writers") | |
715 | ("es" "Herramienta para escritores/as")) | |
716 | #:keywords "manuskript;office;write;edit;novel;text;msk" | |
717 | #:terminal #f | |
718 | #:type "Application" | |
719 | #:icon "manuskript" | |
720 | #:categories "Office;WordProcessor;")) | |
1fffba66 NG |
721 | #t)))))) |
722 | (inputs | |
5dc5a311 | 723 | `(("pandoc" ,pandoc) |
1fffba66 NG |
724 | ("python-lxml" ,python-lxml) |
725 | ("python-markdown" ,python-markdown) | |
726 | ("python-pyqt" ,python-pyqt) | |
727 | ("qtsvg" ,qtsvg))) | |
728 | (home-page "http://www.theologeek.ch/manuskript/") | |
729 | (synopsis "Tool for writers") | |
730 | (description "Manuskript provides a rich environment to help | |
731 | writers create their first draft and then further refine and edit | |
732 | their masterpiece. With Manuskript you can: | |
733 | ||
734 | @itemize | |
735 | @item Grow your premise from one sentence, to a paragraph, to a full | |
736 | summary, | |
737 | @item Create characters, | |
738 | @item Conceive plots, | |
739 | @item Construct outlines (Outline mode and/or Index cards), | |
740 | @item Write with focus (Distraction free mode), | |
741 | @item Build worlds, | |
742 | @item Track items, | |
743 | @item Edit and re-organize chapters and scenes, | |
744 | @item View Story line, | |
745 | @item Compose with fiction or non-fiction templates and writing modes, | |
746 | @item Import and export document formats such as HTML, ePub, | |
747 | OpenDocument, DocX, and more. | |
748 | @end itemize | |
749 | ||
750 | Additionally Manuskript can help in many more ways with a spell | |
751 | checker, markdown highlighter, frequency analyzer, and automatic save | |
752 | in plain text file format.") | |
753 | (license license:gpl3+))) | |
754 | ||
2238211a EF |
755 | (define-public editorconfig-core-c |
756 | (package | |
757 | (name "editorconfig-core-c") | |
7395ea0d | 758 | (version "0.12.4") |
2238211a EF |
759 | (source |
760 | (origin | |
761 | (method git-fetch) | |
762 | (uri (git-reference | |
b0e7b699 | 763 | (url "https://github.com/editorconfig/editorconfig-core-c") |
2238211a EF |
764 | (commit (string-append "v" version)))) |
765 | (file-name (git-file-name name version)) | |
766 | (sha256 | |
7395ea0d | 767 | (base32 "1311fhh2jfsja2hhk3nwb6nijlq03jw8dk35cwbrac0p9jvy03jx")))) |
2238211a EF |
768 | (build-system cmake-build-system) |
769 | (arguments | |
770 | '(#:phases | |
771 | (modify-phases %standard-phases | |
772 | (add-after 'unpack 'insert-tests | |
773 | (lambda* (#:key inputs #:allow-other-keys) | |
774 | (let ((tests (assoc-ref inputs "tests"))) | |
775 | (copy-recursively tests "tests")) | |
1c4b3512 TGR |
776 | #t)) |
777 | (add-after 'install 'delete-static-library | |
778 | (lambda* (#:key outputs #:allow-other-keys) | |
779 | (let* ((out (assoc-ref outputs "out")) | |
780 | (lib (string-append out "/lib"))) | |
781 | (with-directory-excursion lib | |
782 | (delete-file "libeditorconfig_static.a")) | |
783 | #t)))))) | |
2238211a | 784 | (native-inputs |
7395ea0d TGR |
785 | `(("tests" |
786 | ,(origin | |
787 | (method git-fetch) | |
788 | (uri (git-reference | |
789 | (url "https://github.com/editorconfig/editorconfig-core-test") | |
790 | ;; The tests submodule commit matching this package's version. | |
791 | (commit "48610d43b7455af12195473377f93c4ceea654f5"))) | |
792 | (file-name (git-file-name "editorconfig-core-test" version)) | |
793 | (sha256 | |
794 | (base32 "1s29p4brmcsc3xsww3gk85dg45f1kk3iykh1air3ij0hymf5dyqy")))))) | |
2238211a EF |
795 | (inputs |
796 | `(("pcre2" ,pcre2))) | |
797 | (home-page "https://editorconfig.org/") | |
798 | (synopsis "EditorConfig core library written in C") | |
799 | (description "EditorConfig makes it easy to maintain the correct coding | |
800 | style when switching between different text editors and between different | |
801 | projects. The EditorConfig project maintains a file format and plugins for | |
802 | various text editors which allow this file format to be read and used by those | |
803 | editors.") | |
804 | (license license:bsd-2))) | |
75a137da AE |
805 | |
806 | (define-public texmacs | |
807 | (package | |
808 | (name "texmacs") | |
ae6d19e7 | 809 | (version "1.99.19") |
75a137da AE |
810 | (source |
811 | (origin | |
812 | (method url-fetch) | |
813 | (uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/" | |
814 | "source/TeXmacs-" version "-src.tar.gz")) | |
815 | (sha256 | |
ae6d19e7 | 816 | (base32 "1izwqb0z4gqiglv57mjswk6sjivny73kd2sxrf3nmj7wr12pn5m8")))) |
75a137da AE |
817 | (build-system gnu-build-system) |
818 | (native-inputs | |
eaf5df6b NG |
819 | `(("pkg-config" ,pkg-config) |
820 | ("xdg-utils" ,xdg-utils))) ;for xdg-icon-resource | |
75a137da AE |
821 | (inputs |
822 | `(("freetype" ,freetype) | |
823 | ("guile" ,guile-1.8) | |
824 | ("perl" ,perl) | |
825 | ("python" ,python-wrapper) | |
7140c55d ZZ |
826 | ("qt" ,qtbase) |
827 | ("qtsvg" ,qtsvg))) | |
75a137da | 828 | (arguments |
ad9fd1ba | 829 | `(#:tests? #f ; no check target |
75a137da AE |
830 | #:phases |
831 | (modify-phases %standard-phases | |
eaf5df6b NG |
832 | (add-after 'unpack 'fix-icon-directory |
833 | (lambda* (#:key outputs #:allow-other-keys) | |
834 | (let ((out (assoc-ref outputs "out"))) | |
835 | (substitute* "packages/linux/icons.sh" | |
836 | (("/usr/share") | |
837 | (string-append out "/share"))) | |
838 | #t))) | |
d5909136 MD |
839 | (add-after 'install 'install-desktop-file |
840 | (lambda* (#:key outputs #:allow-other-keys) | |
841 | ;; Install desktop file. | |
842 | (let* ((out (assoc-ref outputs "out")) | |
843 | (apps (string-append out "/share/applications")) | |
844 | (source "TeXmacs/misc/mime/texmacs.desktop")) | |
845 | (install-file source apps) | |
846 | #t))) | |
75a137da AE |
847 | (add-before 'configure 'gzip-flags |
848 | (lambda _ | |
849 | (substitute* "Makefile.in" | |
850 | (("^GZIP = gzip -f") "GZIP = gzip -f -n"))))))) | |
851 | (synopsis "Editing platform with special features for scientists") | |
852 | (description | |
853 | "GNU TeXmacs is a text editing platform which is specialized for | |
eaf5df6b NG |
854 | scientists. It is ideal for editing structured documents with different types |
855 | of content. It has robust support for mathematical formulas and plots. It | |
856 | can also act as an interface to external mathematical programs such as R and | |
857 | Octave. TeXmacs is completely extensible via Guile.") | |
75a137da AE |
858 | (license license:gpl3+) |
859 | (home-page "https://www.texmacs.org/tmweb/home/welcome.en.html"))) | |
c55cd98c NG |
860 | |
861 | (define-public scintilla | |
862 | (package | |
863 | (name "scintilla") | |
9d92819d | 864 | (version "5.0.1") |
3e6cb583 NG |
865 | (source |
866 | (origin | |
867 | (method url-fetch) | |
868 | (uri (let ((v (apply string-append (string-split version #\.)))) | |
869 | (string-append "https://www.scintilla.org/scintilla" v ".tgz"))) | |
870 | (sha256 | |
9d92819d | 871 | (base32 "0w5550fijkhmzvdydd8770qq9dgnbq1sd0a8rn4g6mwyfpcyhbfy")))) |
c55cd98c NG |
872 | (build-system gnu-build-system) |
873 | (arguments | |
874 | `(#:make-flags (list "GTK3=1" "CC=gcc" "-Cgtk") | |
875 | #:tests? #f ;require un-packaged Pyside | |
876 | #:phases | |
877 | (modify-phases %standard-phases | |
878 | (delete 'configure) ;no configure script | |
c55cd98c | 879 | (replace 'install |
b2dbc53e | 880 | ;; Upstream provides no install script. |
c55cd98c NG |
881 | (lambda* (#:key outputs #:allow-other-keys) |
882 | (let* ((out (assoc-ref outputs "out")) | |
883 | (lib (string-append out "/lib")) | |
884 | (include (string-append out "/include"))) | |
b2dbc53e NG |
885 | (for-each (lambda (f) (install-file f lib)) |
886 | (find-files "bin/" "\\.so$")) | |
c55cd98c NG |
887 | (for-each (lambda (f) (install-file f include)) |
888 | (find-files "include/" ".")) | |
889 | #t)))))) | |
890 | (native-inputs | |
9d92819d NG |
891 | `(("gcc" ,gcc-9) ;Code has C++17 requirements |
892 | ("pkg-config" ,pkg-config) | |
dee632a8 | 893 | ("python" ,python-wrapper))) |
c55cd98c NG |
894 | (inputs |
895 | `(("gtk+" ,gtk+))) | |
896 | (home-page "https://www.scintilla.org/") | |
897 | (synopsis "Code editor for GTK+") | |
898 | (description "Scintilla is a source code editing component for | |
899 | GTK+. It has the usual features found in text editing components, as | |
900 | well as some that are especially useful for editing and debugging | |
901 | source code; these include support for syntax styling, error | |
902 | indicators, code completion and call tips. Styling choices are more | |
903 | open than with many editors: Scintilla lets you use proportional | |
904 | fonts, bold and italics, multiple foreground and background colours, | |
905 | and multiple fonts.") | |
906 | (license license:hpnd))) | |
2363ed01 NG |
907 | |
908 | (define-public geany | |
909 | (package | |
910 | (name "geany") | |
4496e038 | 911 | (version "1.37.1") |
9e03ddc5 NG |
912 | (source |
913 | (origin | |
914 | (method url-fetch) | |
915 | (uri (string-append "https://download.geany.org/" | |
916 | "geany-" version ".tar.bz2")) | |
917 | (sha256 | |
4496e038 | 918 | (base32 "060sachn33xpx3a609f09y97qq5ky17gvv686zbvrn618ij7bi8q")))) |
2363ed01 NG |
919 | (build-system gnu-build-system) |
920 | (native-inputs | |
921 | `(("autoconf" ,autoconf) | |
922 | ("automake" ,automake) | |
923 | ("doxygen" ,doxygen) | |
924 | ("glib" ,glib "bin") | |
925 | ("intltool" ,intltool) | |
926 | ("libtool" ,libtool) | |
927 | ("pkg-config" ,pkg-config) | |
928 | ("python-docutils" ,python-docutils))) ;for rst2html | |
929 | (inputs | |
930 | `(("gtk+" ,gtk+) | |
9e03ddc5 NG |
931 | ;; FIXME: Geany bundles a 3.X release of Scintilla. It is not |
932 | ;; currently possible to replace it with our Scintilla package. | |
933 | ;; ("scintilla" ,scintilla) | |
934 | )) | |
2363ed01 | 935 | (arguments |
f3ed5297 NG |
936 | `(#:imported-modules ((guix build glib-or-gtk-build-system) |
937 | ,@%gnu-build-system-modules) | |
938 | #:modules (((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) | |
939 | (guix build gnu-build-system) | |
940 | (guix build utils)) | |
941 | #:phases | |
2363ed01 | 942 | (modify-phases %standard-phases |
f3ed5297 NG |
943 | (add-after 'install 'glib-or-gtk-wrap |
944 | (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))))) | |
2363ed01 NG |
945 | (home-page "https://www.geany.org") |
946 | (synopsis "Fast and lightweight IDE") | |
947 | (description "Geany is a small and fast Integrated Development | |
948 | Environment (IDE) that only has a few dependencies on other packages and is as | |
949 | independent as possible from special desktop environments like KDE or GNOME. | |
950 | ||
951 | The basic features of Geany are: | |
952 | @itemize | |
953 | @item syntax highlighting | |
954 | @item code completion | |
955 | @item auto completion of often constructed constructs like if, for and while | |
956 | @item auto completion of XML and HTML tags | |
957 | @item call tips | |
958 | @item folding | |
959 | @item many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal | |
960 | @item symbol lists | |
961 | @item embedded terminal emulation | |
962 | @item extensibility through plugins | |
963 | @end itemize") | |
964 | (license license:gpl2+))) | |
2207d522 NG |
965 | |
966 | (define-public fe | |
967 | (package | |
968 | (name "fe") | |
24652f9c | 969 | ;; Stable release is 1.9. However, this development version |
2207d522 NG |
970 | ;; introduces support for UTF-8. |
971 | (version "2.0") | |
972 | (source (origin | |
973 | (method url-fetch) | |
974 | (uri (string-append "http://www.moria.de/~michael/fe/" | |
975 | "fe-" version ".tar.gz")) | |
976 | (sha256 | |
977 | (base32 | |
24652f9c | 978 | "10mk5wc3dsdp46b3hkjyd740gcdv6m1gvlr3p8xjxf55b3vfs0la")))) |
2207d522 NG |
979 | (build-system gnu-build-system) |
980 | (arguments | |
981 | `(#:tests? #f ;no test | |
982 | ;; Sendmail is only used to send a crash log. Disable the | |
983 | ;; feature since it is (1) undocumented (2) not very useful. | |
984 | #:configure-flags (list "--disable-sendmail") | |
985 | #:phases | |
986 | (modify-phases %standard-phases | |
987 | (add-after 'install 'install-doc | |
988 | (lambda* (#:key outputs #:allow-other-keys) | |
989 | (let* ((out (assoc-ref outputs "out")) | |
990 | (doc (string-append out "/share/doc/" ,name "-" ,version))) | |
991 | (for-each (lambda (f) (install-file f doc)) | |
992 | '("fe.doc" "fe.html" "fe.ps" "feref.ps" "README")) | |
993 | #t)))))) | |
994 | (native-inputs | |
995 | `(("gettext" ,gettext-minimal))) | |
996 | (inputs | |
997 | `(("ncurses" ,ncurses))) | |
998 | (home-page "http://www.moria.de/~michael/fe/") | |
999 | (synopsis "Small folding editor") | |
eee98f96 | 1000 | (description "Fe is a small folding editor. It folds |
2207d522 NG |
1001 | arbitrary text regions; it is not bound to syntactic units. |
1002 | ||
1003 | Fe has no configuration or extension language and requires no setup. | |
99ce2055 | 1004 | Its user interface is emacs-like and it has menus for the very most |
2207d522 NG |
1005 | important functions to help beginners. Further there is a reference |
1006 | card. It offers: | |
1007 | ||
1008 | @itemize | |
1009 | @item Regions and Emacs-like kill ring | |
1010 | @item Incremental search | |
1011 | @item Keyboard macros | |
1012 | @item Editing binary files | |
1013 | @item Multiple windows and views | |
1014 | @item Compose function for Latin 1 characters | |
1015 | @end itemize") | |
1016 | (license license:gpl2+))) | |
a78364e9 DM |
1017 | |
1018 | (define-public ne | |
1019 | (package | |
1020 | (name "ne") | |
a5526c75 | 1021 | (version "3.3.0") |
a78364e9 DM |
1022 | (source (origin |
1023 | (method git-fetch) | |
1024 | (uri (git-reference | |
b0e7b699 | 1025 | (url "https://github.com/vigna/ne") |
a78364e9 DM |
1026 | (commit version))) |
1027 | (file-name (git-file-name name version)) | |
1028 | (sha256 | |
1029 | (base32 | |
a5526c75 | 1030 | "01aglnsfljlvx0wvyvpjfn4y88jf450a06qnj9a8lgdqv1hdkq1a")))) |
a78364e9 DM |
1031 | (build-system gnu-build-system) |
1032 | (native-inputs | |
1033 | `(("perl" ,perl) | |
1034 | ("texinfo" ,texinfo))) | |
1035 | (inputs | |
1036 | `(("ncurses" ,ncurses))) | |
1037 | (arguments | |
1038 | `(#:tests? #f | |
1039 | #:make-flags | |
1040 | (list "CC=gcc" | |
1041 | (string-append "PREFIX=" (assoc-ref %outputs "out")) | |
1042 | (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses") | |
1043 | "/lib")) | |
1044 | #:phases | |
1045 | (modify-phases %standard-phases | |
1046 | (replace 'configure | |
1047 | (lambda _ | |
1048 | (substitute* "src/makefile" | |
1049 | (("-lcurses") "-lncurses")) | |
1050 | #t))))) | |
d12d52ce | 1051 | (home-page "https://ne.di.unimi.it/") |
a78364e9 DM |
1052 | (synopsis "Text editor with menu bar") |
1053 | (description "This package provides a modeless text editor with menu bar. | |
1054 | It supports syntax highlighting, regular expressions, configurable menus, | |
1055 | keybindings, autocomplete and unlimited undo. It can pipe a marked block | |
1056 | of text through any command line filter. It can also open very large binary | |
1057 | files. It was originally developed on the Amiga 3000T.") | |
1058 | (license license:gpl3+))) | |
8b95f741 T |
1059 | |
1060 | (define-public hexer | |
1061 | (package | |
1062 | (name "hexer") | |
1063 | (version "1.0.6") | |
1064 | (source | |
1065 | (origin | |
1066 | (method url-fetch) | |
1067 | (uri (string-append "https://devel.ringlet.net/files/editors/hexer/" | |
1068 | "hexer-" version ".tar.xz")) | |
1069 | (sha256 | |
1070 | (base32 "157z17z8qivdin2km2wp86x1bv1nx15frrwcz11mk0l3ab74mf76")))) | |
1071 | (build-system gnu-build-system) | |
1072 | (arguments | |
1073 | `(#:tests? #f ;no upstream tests | |
1074 | #:make-flags | |
1075 | (list "CC=gcc" | |
1076 | (string-append "PREFIX=" (assoc-ref %outputs "out")) | |
1077 | (string-append "LTERMCAP=-lncurses") | |
1078 | (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses") | |
1079 | "/lib")) | |
1080 | #:phases | |
1081 | (modify-phases %standard-phases | |
1082 | (delete 'configure)))) ;no configure script | |
1083 | (inputs | |
1084 | `(("ncurses" ,ncurses))) | |
1085 | (home-page "https://devel.ringlet.net/editors/hexer/") | |
1086 | (synopsis "Multi buffer editor for binary files with vi-like interface") | |
1087 | (description "Hexer is a multi-buffer editor for binary files for Unix-like | |
1088 | systems that displays its buffer(s) as a hex dump. The user interface is kept | |
1089 | similar to vi/ex.") | |
1090 | (license license:bsd-3))) | |
e530fb41 MM |
1091 | |
1092 | (define-public virtaal | |
1093 | (package | |
1094 | (name "virtaal") | |
1095 | (version "0.7.1") | |
1096 | (source (origin | |
1097 | (method url-fetch) | |
1098 | (uri (string-append "mirror://sourceforge/translate/Virtaal/" | |
1099 | version "/virtaal-" version ".tar.bz2")) | |
1100 | (sha256 | |
1101 | (base32 | |
1102 | "0cyimjp3191qlmw6n0ipqdr9xr0cq4f6dqvz4rl9q31h6l3kywf9")))) | |
1103 | (build-system python-build-system) | |
1104 | (arguments | |
1105 | `(#:python ,python-2 | |
1106 | #:use-setuptools? #f | |
1107 | #:tests? #f ;; Failing tests | |
1108 | #:phases | |
1109 | (modify-phases %standard-phases | |
1110 | (add-before 'build 'configure | |
1111 | (lambda* (#:key outputs #:allow-other-keys) | |
1112 | ;; Set data file path to absolute store path. | |
1113 | (substitute* "virtaal/common/pan_app.py" | |
1114 | (("file_discovery\\.get_abs_data_filename.*") | |
1115 | (string-append "os.path.join('" | |
1116 | (assoc-ref outputs "out") | |
1117 | "/share', *path_parts)")))))))) | |
1118 | (inputs | |
1119 | `(("python2-lxml" ,python2-lxml) | |
1120 | ("python2-pygtk" ,python2-pygtk) | |
1121 | ("python2-simplejson" ,python2-simplejson) | |
1122 | ("python2-translate-toolkit" ,python2-translate-toolkit) | |
1123 | ("python2-pycurl" ,python2-pycurl))) | |
1124 | (synopsis "Graphical translation tool") | |
1125 | (description "Virtaal is a powerful yet simple translation tool with an | |
1126 | uncluttered user interface. It supports a multitude of translation formats | |
1127 | provided by the Translate Toolkit, including XLIFF and PO.") | |
1128 | (home-page "https://virtaal.translatehouse.org/") | |
1129 | (license license:gpl2+))) |