1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2016 José Miguel Sánchez García <jmi2k@openmailbox.org>
3 ;;; Copyright © 2016 Carlo Zancanaro <carlo@zancanaro.id.au>
4 ;;; Copyright © 2017, 2018, 2020 Eric Bavier <bavier@posteo.net>
5 ;;; Copyright © 2017 Feng Shu <tumashu@163.com>
6 ;;; Copyright © 2017 Nikita <nikita@n0.is>
7 ;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.org>
8 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
9 ;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
10 ;;; Copyright © 2019 Andreas Enge <andreas@enge.fr>
11 ;;; Copyright © 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
12 ;;; Copyright © 2020 Marius Bakke <mbakke@fastmail.com>
13 ;;; Copyright © 2020 Tom Zander <tomz@freedommail.ch>
15 ;;; This file is part of GNU Guix.
17 ;;; GNU Guix is free software; you can redistribute it and/or modify it
18 ;;; under the terms of the GNU General Public License as published by
19 ;;; the Free Software Foundation; either version 3 of the License, or (at
20 ;;; your option) any later version.
22 ;;; GNU Guix is distributed in the hope that it will be useful, but
23 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
24 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 ;;; GNU General Public License for more details.
27 ;;; You should have received a copy of the GNU General Public License
28 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
30 (define-module (gnu packages text-editors)
31 #:use-module (guix packages)
32 #:use-module (guix download)
33 #:use-module (guix git-download)
34 #:use-module (guix utils)
35 #:use-module (guix build-system cmake)
36 #:use-module (guix build-system gnu)
37 #:use-module (guix build-system cmake)
38 #:use-module (guix build-system glib-or-gtk)
39 #:use-module (guix build-system python)
40 #:use-module ((guix licenses) #:prefix license:)
41 #:use-module (gnu packages)
42 #:use-module (gnu packages aspell)
43 #:use-module (gnu packages assembly)
44 #:use-module (gnu packages autotools)
45 #:use-module (gnu packages boost)
46 #:use-module (gnu packages documentation)
47 #:use-module (gnu packages fontutils)
48 #:use-module (gnu packages gcc)
49 #:use-module (gnu packages gettext)
50 #:use-module (gnu packages glib)
51 #:use-module (gnu packages gtk)
52 #:use-module (gnu packages guile)
53 #:use-module (gnu packages haskell-xyz)
54 #:use-module (gnu packages libbsd)
55 #:use-module (gnu packages libreoffice)
56 #:use-module (gnu packages llvm)
57 #:use-module (gnu packages lua)
58 #:use-module (gnu packages ncurses)
59 #:use-module (gnu packages pcre)
60 #:use-module (gnu packages perl)
61 #:use-module (gnu packages pkg-config)
62 #:use-module (gnu packages python)
63 #:use-module (gnu packages python-xyz)
64 #:use-module (gnu packages qt)
65 #:use-module (gnu packages regex)
66 #:use-module (gnu packages ruby)
67 #:use-module (gnu packages terminals)
68 #:use-module (gnu packages texinfo)
69 #:use-module (gnu packages version-control)
70 #:use-module (gnu packages xml)
71 #:use-module (gnu packages xorg))
79 (uri (string-append "https://github.com/martanne/vis/releases"
81 "/vis-v" version ".tar.gz"))
84 "0aw35n8xk7ir84ckvczc6yshj9ynishrlz0qlv4yc1afbra1gxmn"))))
85 (build-system gnu-build-system)
87 `(#:test-target "test"
88 #:tests? #f ; no releases; snapshots are missing tests
90 (modify-phases %standard-phases
91 (add-after 'install 'wrap-binary
92 (lambda* (#:key inputs outputs #:allow-other-keys)
93 (let* ((out (assoc-ref outputs "out"))
94 (lpeg (assoc-ref inputs "lua-lpeg"))
95 (lua-version ,(version-major+minor (package-version lua)))
96 (LUA_PATH (string-append lpeg "/share/lua/"
97 lua-version "/?.lua"))
98 (LUA_CPATH (string-append lpeg "/lib/lua/"
99 lua-version "/?.so")))
100 (wrap-program (string-append out "/bin/vis")
101 `("LUA_PATH" ":" prefix (,LUA_PATH))
102 `("LUA_CPATH" ":" prefix (,LUA_CPATH)))
105 (list (search-path-specification
106 (variable "VIS_PATH")
107 (files '("share/vis")))))
108 (inputs `(("lua" ,lua)
110 ("libtermkey" ,libtermkey)
111 ("lua-lpeg" ,lua-lpeg)
113 (synopsis "Vim-like text editor")
115 "Vis aims to be a modern, legacy free, simple yet efficient vim-like text
116 editor. It extends vim's modal editing with built-in support for multiple
117 cursors/selections and combines it with sam's structural regular expression
118 based command language.")
119 (home-page "https://github.com/martanne/vis")
120 (license (list license:isc ; Main distribution.
121 license:public-domain ; map.[ch]
122 license:expat)))) ; lexers and libutf.[ch]
124 (define-public kakoune
127 (version "2020.01.16")
131 (uri (string-append "https://github.com/mawww/kakoune/"
132 "releases/download/v" version "/"
133 "kakoune-" version ".tar.bz2"))
135 (base32 "1bhd990gywdwdhxc5dn83wwj418c5cw1ndqycf7k0a02kxlg3550"))))
136 (build-system gnu-build-system)
139 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
141 (modify-phases %standard-phases
142 (add-after 'unpack 'patch-source
144 ;; kakoune uses confstr with _CS_PATH to find out where to find
145 ;; a posix shell, but this doesn't work in the build
146 ;; environment. This substitution just replaces that result
147 ;; with the "sh" path.
148 (substitute* "src/shell_manager.cc"
149 (("if \\(m_shell.empty\\(\\)\\)" line)
150 (string-append "m_shell = \"" (which "sh")
153 (delete 'configure) ; no configure script
154 ;; kakoune requires us to be in the src/ directory to build
155 (add-before 'build 'chdir
156 (lambda _ (chdir "src") #t)))))
158 `(("asciidoc" ,asciidoc)
159 ("pkg-config" ,pkg-config)
162 `(("ncurses" ,ncurses)))
163 (synopsis "Vim-inspired code editor")
165 "Kakoune is a code editor heavily inspired by Vim, as such most of its
166 commands are similar to Vi's ones, and it shares Vi's \"keystrokes as a text
167 editing language\" model. Kakoune has a strong focus on interactivity, most
168 commands provide immediate and incremental results, while still being
169 competitive (as in keystroke count) with Vim.")
170 (home-page "https://kakoune.org/")
171 (license license:unlicense)))
180 (uri (string-append "https://sourceforge.net/projects/joe-editor/"
181 "files/JOE sources/joe-" version "/"
182 "joe-" version ".tar.gz"))
185 "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9"))))
186 (build-system gnu-build-system)
187 (inputs `(("ncurses" ,ncurses)))
188 (home-page "http://joe-editor.sourceforge.net/")
189 (synopsis "Console screen editor")
191 "JOE is a powerful console screen editor with a \"mode-less\" user
192 interface similar to many user-friendly editors. JOE has some of the key
193 bindings and many of the powerful features of GNU Emacs.")
194 (license license:gpl3+)))
196 (define-public jucipp
200 (home-page "https://gitlab.com/cppit/jucipp")
203 (uri (git-reference (url home-page)
204 (commit (string-append "v" version))
205 ;; Two submodules are required which are
206 ;; developed alongside JuCi++ and difficult
207 ;; to package separately.
209 (file-name (git-file-name name version))
211 (base32 "0v7fmsya2zn1xx59bkv4cbyinmcnv52hm4j40nbfwalcks631xrr"))))
212 (build-system cmake-build-system)
214 `(#:configure-flags '("-DBUILD_TESTING=ON"
216 ;; These arguments are here to facilitate an "in-source"
217 ;; build using "./build" instead of the default "../build".
218 ;; The test suite expects that to be the case.
221 #:phases (modify-phases %standard-phases
222 (add-before 'configure 'enter-build-directory
228 ;; This phase is necessary to fix a test failure, see
229 ;; <https://gitlab.com/cppit/jucipp/-/issues/423>.
230 (add-after 'unpack 'add-reference-to-clang-internal-header
231 (lambda* (#:key inputs #:allow-other-keys)
232 (substitute* "src/compile_commands.cc"
233 ((".*-I/usr/lib/clang.*" all)
234 (string-append "arguments.emplace_back(\"-I"
235 (assoc-ref inputs "libclang")
237 ,@(list (package-version clang))
241 (add-after 'unpack 'patch-tiny-process-library
243 (with-directory-excursion "lib/tiny-process-library"
244 (substitute* '("process_unix.cpp"
246 (("/bin/sh") (which "sh"))))
248 (add-after 'unpack 'disable-git-test
250 (substitute* "tests/CMakeLists.txt"
251 ;; Disable the git test, as it requires the full checkout.
252 (("add_test\\(git_test.*\\)") ""))
254 (add-before 'check 'pre-check
255 (lambda* (#:key inputs #:allow-other-keys)
256 ;; Tests do not expect HOME to be empty.
257 (setenv "HOME" "/etc")
259 ;; Most tests require an X server.
260 (let ((xorg-server (assoc-ref inputs "xorg-server"))
262 (setenv "DISPLAY" display)
263 (system (string-append xorg-server "/bin/Xvfb "
267 `(("pkg-config" ,pkg-config)
268 ("xorg-server" ,xorg-server-for-tests)))
273 ("gtksourceviewmm" ,gtksourceviewmm)
275 ("libgit2" ,libgit2)))
276 (synopsis "Lightweight C++ IDE")
278 "juCi++ is a small @dfn{IDE} (Integrated Development Environment)
279 designed especially towards libclang with speed, stability, and ease of use
282 It supports autocompletion, on-the-fly warnings and errors, syntax
283 highlighting, and integrates with Git as well as the CMake and Meson build
285 (license license:expat)))
287 (define-public leafpad
293 (uri (string-append "mirror://savannah/"
294 "leafpad/leafpad-" version ".tar.gz"))
297 "0b0az2wvqgvam7w0ns1j8xp2llslm1rx6h7zcsy06a7j0yp257cm"))))
298 (build-system glib-or-gtk-build-system)
300 `(("intltool" ,intltool)
301 ("pkg-config" ,pkg-config)))
304 (home-page "http://tarot.freeshell.org/leafpad/")
305 (synopsis "GTK+ based text editor")
306 (description "Leafpad is a GTK+ text editor that emphasizes simplicity. As
307 development focuses on keeping weight down to a minimum, only the most essential
308 features are implemented in the editor. Leafpad is simple to use, is easily
309 compiled, requires few libraries, and starts up quickly. ")
310 (license license:gpl2+)))
318 (uri (string-append "https://sites.google.com/site/e3editor/Home/"
319 "e3-" version ".tgz"))
322 "0919kadkas020maqq37852isnzp053q2fnws2zh3mz81d1jiviak"))
323 (modules '((guix build utils)))
325 ;; Remove pre-built binaries.
327 (delete-file-recursively "bin")
329 (build-system gnu-build-system)
332 #:make-flags (list (string-append "PREFIX="
333 (assoc-ref %outputs "out")))
334 #:phases (modify-phases %standard-phases
335 (delete 'configure))))
338 (home-page "https://sites.google.com/site/e3editor/")
339 (synopsis "Tiny text editor written in assembly")
341 "e3 is a micro text editor with an executable code size between 3800 and
342 35000 bytes. Except for ``syntax highlighting'', the e3 binary supports all
343 of the basic functions one expects plus built in arithmetic calculations.
344 UTF-8 coding of unicode characters is supported as well. e3 can use
345 Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings. e3 can be used on
346 16, 32, and 64-bit CPUs.")
347 (supported-systems '("x86_64-linux" "i686-linux"))
348 (license license:gpl2+)))
357 (url "https://github.com/hboetes/mg")
359 (file-name (git-file-name name version))
362 "14vrm8lvwksf697sqks7xfd1xaqjlqjc9afjk33sksq5p27wr203"))
363 (modules '((guix build utils)))
365 (substitute* "GNUmakefile"
368 (build-system gnu-build-system)
370 `(("pkg-config" ,pkg-config)))
373 ("ncurses" ,ncurses)))
375 ;; No test suite available.
377 #:make-flags (list (string-append "prefix=" %output)
379 #:phases (modify-phases %standard-phases
380 (delete 'configure) ; no configure script
381 (add-before 'build 'correct-location-of-difftool
383 (substitute* "buffer.c"
387 (add-before 'install 'patch-tutorial-location
388 (lambda* (#:key outputs #:allow-other-keys)
390 (("/usr") (assoc-ref outputs "out")))
392 (add-after 'install 'install-tutorial
393 (lambda* (#:key outputs #:allow-other-keys)
394 (let* ((out (assoc-ref outputs "out"))
395 (doc (string-append out "/share/doc/mg")))
396 (install-file "tutorial" doc)
398 (home-page "https://homepage.boetes.org/software/mg/")
399 (synopsis "Microscopic GNU Emacs clone")
401 "Mg (@command{mg}) is a GNU Emacs style editor, with which it is
402 \"broadly\" compatible. This is a portable version of the mg maintained by the
404 (license license:public-domain)))
406 (define-public qemacs
413 (uri (string-append "https://bellard.org/qemacs/"
414 "qemacs-" version ".tar.gz"))
416 (base32 "156z4wpj49i6j388yjird5qvrph7hz0grb4r44l4jf3q8imadyrg"))))
417 (build-system gnu-build-system)
419 `(#:tests? #f ;no test
421 (modify-phases %standard-phases
422 (add-before 'build 'build-qhtml
423 ;; Build fails without first creating qHTML library.
424 (lambda _ (invoke "make" "-C" "libqhtml")))
425 (add-before 'install 'fix-man-pages-directory
426 ;; Install in $out/share/man instead of $out/man.
428 (substitute* "Makefile"
429 (("/man/man1" all) (string-append "/share" all)))
431 (add-before 'install 'create-directories
432 ;; Ensure directories exist before installing files.
433 (lambda* (#:key outputs #:allow-other-keys)
434 (let ((out (assoc-ref outputs "out")))
435 (for-each (lambda (d) (mkdir-p (string-append out d)))
436 '("/bin" "/share/man/man1" "/share/qe"))
438 (add-after 'install 'install-extra-documentation
439 ;; Install sample configuration file, Info, and HTML manual.
440 (lambda* (#:key outputs #:allow-other-keys)
441 (let* ((share (string-append (assoc-ref outputs "out") "/share"))
442 (doc (string-append share "/doc/" ,name "-" ,version))
443 (html (string-append share "/html"))
444 (info (string-append share "/info"))
445 (makeinfo (string-append (assoc-ref %build-inputs "texinfo")
447 ;; First fix Texinfo documentation, create appropriate
448 ;; directories, then generate Info and HTML files there.
449 (substitute* "qe-doc.texi"
450 (("^M-([{}])" _ bracket) (string-append "M-@" bracket)))
451 (for-each (lambda (d) (mkdir-p d)) (list html info))
452 (invoke makeinfo "qe-doc.texi" "-o" info)
453 (invoke makeinfo "qe-doc.texi" "--html" "--no-split" "-o" html)
454 ;; Install sample configuration file.
455 (install-file "config.eg" doc)
458 `(("texinfo" ,texinfo)))
463 (home-page "https://bellard.org/qemacs/")
464 (synopsis "Small but powerful text editor")
465 (description "QEmacs (for Quick Emacs) is a very small but
466 powerful editor. It has features that even big editors lack:
470 @item Full screen editor with an Emacs look and feel with all Emacs
471 common features: multi-buffer, multi-window, command mode, universal
472 argument, keyboard macros, config file with C-like syntax, minibuffer
473 with completion and history.
475 @item Can edit files of hundreds of Megabytes without being slow by
476 using a highly optimized internal representation and by mmaping the
479 @item Full Unicode support, including multi charset handling (8859-x,
480 UTF8, SJIS, EUC-JP, ...) and bidirectional editing respecting the
481 Unicode bidi algorithm. Arabic and Indic scripts handling (in
484 @item WYSIWYG HTML/XML/CSS2 mode graphical editing. Also supports
485 Lynx like rendering on VT100 terminals.
487 @item WYSIWYG DocBook mode based on XML/CSS2 renderer.
489 @item C mode: coloring with immediate update. Emacs like auto-indent.
491 @item Shell mode: colorized VT100 emulation so that your shell work
492 exactly as you expect. Compile mode with next/prev error.
494 @item Input methods for most languages, including Chinese (input
495 methods come from the Yudit editor).
497 @item Hexadecimal editing mode with insertion and block commands.
498 Unicode hexa editing is also supported.
500 @item Works on any VT100 terminals without termcap. UTF8 VT100
501 support included with double width glyphs.
503 @item X11 support. Support multiple proportional fonts at the same
504 time (as XEmacs). X Input methods supported. Xft extension supported
505 for anti aliased font display.
507 @item Small! Full version (including HTML/XML/CSS2/DocBook rendering
508 and all charsets): 200KB big. Basic version (without bidir/unicode
509 scripts/input/X11/C/Shell/HTML/Dired): 49KB.
511 (license license:lgpl2.1+)))
513 (define-public ghostwriter
520 (url "https://github.com/wereturtle/ghostwriter.git")
521 (commit (string-append "v" version))))
522 (file-name (git-file-name name version))
525 "13yn82m1l2pq93wbl569a2lzpc3sn8a8g30hsgdch1l9xlmhwran"))))
526 (build-system gnu-build-system)
528 `(("pkg-config" ,pkg-config)
529 ("qttools" ,qttools))) ; for lrelease
531 `(("hunspell" ,hunspell)
533 ("qtdeclarative" ,qtdeclarative)
534 ("qtmultimedia" ,qtmultimedia)
535 ("qtquickcontrols" ,qtquickcontrols)
537 ("qtwebchannel" ,qtwebchannel)))
538 (propagated-inputs ; To get native-search-path
539 `(("qtwebengine" ,qtwebengine)))
542 (modify-phases %standard-phases
544 (lambda* (#:key outputs #:allow-other-keys)
545 (let ((out (assoc-ref outputs "out")))
546 (invoke "qmake" (string-append "PREFIX=" out)))))
547 (add-after 'configure 'create-translations
549 ;; `lrelease` will not overwrite, so delete existing .qm files
550 (for-each delete-file (find-files "translations" ".*\\.qm"))
551 (apply invoke "lrelease" (find-files "translations" ".*\\.ts"))))
552 ;; Ensure that icons are found at runtime.
553 (add-after 'install 'wrap-executable
554 (lambda* (#:key inputs outputs #:allow-other-keys)
555 (let ((out (assoc-ref outputs "out")))
556 (wrap-program (string-append out "/bin/ghostwriter")
557 `("QT_PLUGIN_PATH" ":" prefix
558 ,(map (lambda (label)
559 (string-append (assoc-ref inputs label)
560 "/lib/qt5/plugins/"))
561 '("qtsvg" "qtmultimedia"))))))))))
562 (home-page "https://wereturtle.github.io/ghostwriter/")
563 (synopsis "Write without distractions")
565 "@code{ghostwriter} provides a relaxing, distraction-free writing
566 environment with Markdown markup.")
567 (license license:gpl3+))) ; icons/* under CC-BY-SA3
569 (define-public manuskript
577 (url "https://github.com/olivierkes/manuskript.git")
579 (file-name (git-file-name name version))
581 (base32 "1l6l9k6k69yv8xqpll0zv9cwdqqg4zvxy90l6sx5nv2yywh5crla"))))
582 (build-system python-build-system)
584 `(#:tests? #f ;no test
586 (modify-phases %standard-phases
590 (lambda* (#:key outputs #:allow-other-keys)
591 (let* ((out (assoc-ref outputs "out"))
592 (share (string-append out "/share/manuskript")))
597 (let ((destination (string-append share "/" d)))
598 (mkdir-p destination)
599 (copy-recursively d destination)))
600 '("bin" "i18n" "icons" "libs" "manuskript" "resources"))
601 ;; Install documentation.
602 (let ((doc (string-append out
603 "/doc/manuskript-" ,version
604 "/sample-projects")))
606 (copy-recursively "sample-projects" doc))
607 ;; Wrap executable in "$out/share/manuskript/bin" and
608 ;; link to it from "$out/bin".
609 (let ((bin (string-append out "/bin"))
610 (executable (string-append share "/bin/manuskript")))
611 (wrap-program executable
612 (list "PYTHONPATH" 'prefix (list (getenv "PYTHONPATH"))))
614 (with-directory-excursion bin
615 (symlink (string-append share "/bin/manuskript")
617 ;; Install icons and create .desktop file.
618 (let ((apps (string-append out "/share/applications"))
619 (icons-dir (string-append out "/share/pixmaps")))
620 (install-file "icons/Manuskript/manuskript.svg" icons-dir)
622 (with-output-to-file (string-append apps "/manuskript.desktop")
627 MimeType=application/x-manuskript-book;~@
628 Exec=~a/bin/manuskript %f~@
629 Comment=Tool for writers~@
630 Comment[es]=Herramienta para escritores/as~@
631 Keywords=manuskript;office;write;edit;novel;text;msk~@
635 Categories=Office;WordProcessor;~%"
639 `(("ghc-pandoc" ,ghc-pandoc)
640 ("python-lxml" ,python-lxml)
641 ("python-markdown" ,python-markdown)
642 ("python-pyqt" ,python-pyqt)
644 (home-page "http://www.theologeek.ch/manuskript/")
645 (synopsis "Tool for writers")
646 (description "Manuskript provides a rich environment to help
647 writers create their first draft and then further refine and edit
648 their masterpiece. With Manuskript you can:
651 @item Grow your premise from one sentence, to a paragraph, to a full
653 @item Create characters,
654 @item Conceive plots,
655 @item Construct outlines (Outline mode and/or Index cards),
656 @item Write with focus (Distraction free mode),
659 @item Edit and re-organize chapters and scenes,
660 @item View Story line,
661 @item Compose with fiction or non-fiction templates and writing modes,
662 @item Import and export document formats such as HTML, ePub,
663 OpenDocument, DocX, and more.
666 Additionally Manuskript can help in many more ways with a spell
667 checker, markdown highlighter, frequency analyzer, and automatic save
668 in plain text file format.")
669 (license license:gpl3+)))
671 (define-public editorconfig-core-c
673 (name "editorconfig-core-c")
679 (url "https://github.com/editorconfig/editorconfig-core-c.git")
680 (commit (string-append "v" version))))
681 (file-name (git-file-name name version))
684 "0jkc69r4jwn4rih6h6cqvgljjc3ff49cxj8286mi515aczr48cm1"))))
685 (build-system cmake-build-system)
688 (modify-phases %standard-phases
689 (add-after 'unpack 'insert-tests
690 (lambda* (#:key inputs #:allow-other-keys)
691 (let ((tests (assoc-ref inputs "tests")))
692 (copy-recursively tests "tests"))
698 (url "https://github.com/editorconfig/editorconfig-core-test")
699 (commit "6ea1d8ece62cac9cf72c79dce4879b046abe1fe7"))) ; matches version
700 (file-name (git-file-name "editorconfig-core-test" version))
703 "1sf6910idnd4bgzbj8w8f9ldsbkaqa0lh6syymwy3hfqda63acj7"))))))
706 (home-page "https://editorconfig.org/")
707 (synopsis "EditorConfig core library written in C")
708 (description "EditorConfig makes it easy to maintain the correct coding
709 style when switching between different text editors and between different
710 projects. The EditorConfig project maintains a file format and plugins for
711 various text editors which allow this file format to be read and used by those
713 (license license:bsd-2)))
715 (define-public texmacs
722 (uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/"
723 "source/TeXmacs-" version "-src.tar.gz"))
725 (base32 "12bp0f34izzqimz49lfpgf4lyz3h45s9xbmk8v6zsawdjki76alg"))
726 (modules '((guix build utils)))
729 (delete-file-recursively "3rdparty")
731 (build-system gnu-build-system)
733 `(("pkg-config" ,pkg-config)))
735 `(("freetype" ,freetype)
738 ("python" ,python-wrapper)
741 `(#:tests? #f ; no check target
743 (modify-phases %standard-phases
744 (add-before 'configure 'gzip-flags
746 (substitute* "Makefile.in"
747 (("^GZIP = gzip -f") "GZIP = gzip -f -n")))))))
748 (synopsis "Editing platform with special features for scientists")
750 "GNU TeXmacs is a text editing platform which is specialized for
751 scientists. It is ideal for editing structured documents with different
752 types of content. It has robust support for mathematical formulas and plots.
753 It can also act as an interface to external mathematical programs such as R
754 and Octave. TeXmacs is completely extensible via Guile.")
755 (license license:gpl3+)
756 (home-page "https://www.texmacs.org/tmweb/home/welcome.en.html")))
758 (define-public scintilla
765 (uri (let ((v (apply string-append (string-split version #\.))))
766 (string-append "https://www.scintilla.org/scintilla" v ".tgz")))
768 (base32 "0zh8c19r1zd4kr9jg2ws0n2n5ic2siz5zbns6cvylyfbpf69ghy2"))))
769 (build-system gnu-build-system)
771 `(#:make-flags (list "GTK3=1" "CC=gcc" "-Cgtk")
772 #:tests? #f ;require un-packaged Pyside
774 (modify-phases %standard-phases
775 (delete 'configure) ;no configure script
776 (add-after 'unpack 'build-shared-library
778 (substitute* "gtk/makefile"
779 (("scintilla\\.a") "libscintilla.so")
780 (("\\$\\(AR\\) \\$\\(ARFLAGS\\) \\$@ \\$\\^")
781 "$(CC) -shared $^ -o $@")
782 (("\\$\\(RANLIB\\) \\$@") ""))
785 (lambda* (#:key outputs #:allow-other-keys)
786 (let* ((out (assoc-ref outputs "out"))
787 (lib (string-append out "/lib"))
788 (include (string-append out "/include")))
789 (install-file "bin/libscintilla.so" lib)
790 (for-each (lambda (f) (install-file f include))
791 (find-files "include/" "."))
794 `(("pkg-config" ,pkg-config)
795 ("python" ,python-wrapper)))
798 (home-page "https://www.scintilla.org/")
799 (synopsis "Code editor for GTK+")
800 (description "Scintilla is a source code editing component for
801 GTK+. It has the usual features found in text editing components, as
802 well as some that are especially useful for editing and debugging
803 source code; these include support for syntax styling, error
804 indicators, code completion and call tips. Styling choices are more
805 open than with many editors: Scintilla lets you use proportional
806 fonts, bold and italics, multiple foreground and background colours,
807 and multiple fonts.")
808 (license license:hpnd)))
816 (uri (string-append "https://download.geany.org/"
817 "geany-" version ".tar.bz2"))
820 "0gnm17cr4rf3pmkf0axz4a0fxwnvp55ji0q0lzy88yqbshyxv14i"))
821 (modules '((guix build utils)))
823 (delete-file-recursively "scintilla")
825 (build-system gnu-build-system)
827 `(("autoconf" ,autoconf)
828 ("automake" ,automake)
831 ("intltool" ,intltool)
833 ("pkg-config" ,pkg-config)
834 ("python-docutils" ,python-docutils))) ;for rst2html
837 ("scintilla" ,scintilla)))
840 (modify-phases %standard-phases
841 (add-after 'unpack 'use-scintilla-shared-library
842 (lambda* (#:key inputs #:allow-other-keys)
843 (substitute* "configure.ac"
844 (("scintilla/Makefile") "")
845 (("scintilla/include/Makefile") ""))
846 (substitute* "Makefile.am"
848 (substitute* "src/Makefile.am"
849 (("\\$\\(top_builddir\\)/scintilla/libscintilla.la") "")
850 (("geany_LDFLAGS =" all) (string-append all " -lscintilla")))
851 (substitute* "doc/Makefile.am"
852 (("\\$\\(INSTALL_DATA\\) \\$\\(top_srcdir\\)/scintilla/License.txt \\$\\(DOCDIR\\)/ScintillaLicense.txt") ""))
853 (substitute* "tests/Makefile.am"
854 (("AM_LDFLAGS =" all) (string-append all " -lscintilla")))
855 (for-each delete-file (list "autogen.sh" "configure" "Makefile.in"))
857 (home-page "https://www.geany.org")
858 (synopsis "Fast and lightweight IDE")
859 (description "Geany is a small and fast Integrated Development
860 Environment (IDE) that only has a few dependencies on other packages and is as
861 independent as possible from special desktop environments like KDE or GNOME.
863 The basic features of Geany are:
865 @item syntax highlighting
866 @item code completion
867 @item auto completion of often constructed constructs like if, for and while
868 @item auto completion of XML and HTML tags
871 @item many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal
873 @item embedded terminal emulation
874 @item extensibility through plugins
876 (license license:gpl2+)))
881 ;; Stable release is 1.8. However, this development version
882 ;; introduces support for UTF-8.
886 (uri (string-append "http://www.moria.de/~michael/fe/"
887 "fe-" version ".tar.gz"))
890 "1hwws7si1752z6hp61zxznvgsb6846lp8zl1hn5ddhsbafwalwb9"))))
891 (build-system gnu-build-system)
893 `(#:tests? #f ;no test
894 ;; Sendmail is only used to send a crash log. Disable the
895 ;; feature since it is (1) undocumented (2) not very useful.
896 #:configure-flags (list "--disable-sendmail")
898 (modify-phases %standard-phases
899 (add-after 'install 'install-doc
900 (lambda* (#:key outputs #:allow-other-keys)
901 (let* ((out (assoc-ref outputs "out"))
902 (doc (string-append out "/share/doc/" ,name "-" ,version)))
903 (for-each (lambda (f) (install-file f doc))
904 '("fe.doc" "fe.html" "fe.ps" "feref.ps" "README"))
907 `(("gettext" ,gettext-minimal)))
909 `(("ncurses" ,ncurses)))
910 (home-page "http://www.moria.de/~michael/fe/")
911 (synopsis "Small folding editor")
912 (description "Fe is a small folding editor. It folds
913 arbitrary text regions; it is not bound to syntactic units.
915 Fe has no configuration or extension language and requires no setup.
916 Its user interface is emacs-like and it has menus for the very most
917 important functions to help beginners. Further there is a reference
921 @item Regions and Emacs-like kill ring
922 @item Incremental search
923 @item Keyboard macros
924 @item Editing binary files
925 @item Multiple windows and views
926 @item Compose function for Latin 1 characters
928 (license license:gpl2+)))
937 (url "https://github.com/vigna/ne.git")
939 (file-name (git-file-name name version))
942 "0h6d08cnwrk96ss83i9bragwwanph6x54sm3ak1z81146dsqsiif"))))
943 (build-system gnu-build-system)
946 ("texinfo" ,texinfo)))
948 `(("ncurses" ,ncurses)))
953 (string-append "PREFIX=" (assoc-ref %outputs "out"))
954 (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses")
957 (modify-phases %standard-phases
960 (substitute* "src/makefile"
961 (("-lcurses") "-lncurses"))
963 (home-page "http://ne.di.unimi.it/")
964 (synopsis "Text editor with menu bar")
965 (description "This package provides a modeless text editor with menu bar.
966 It supports syntax highlighting, regular expressions, configurable menus,
967 keybindings, autocomplete and unlimited undo. It can pipe a marked block
968 of text through any command line filter. It can also open very large binary
969 files. It was originally developed on the Amiga 3000T.")
970 (license license:gpl3+)))
979 (uri (string-append "https://devel.ringlet.net/files/editors/hexer/"
980 "hexer-" version ".tar.xz"))
982 (base32 "157z17z8qivdin2km2wp86x1bv1nx15frrwcz11mk0l3ab74mf76"))))
983 (build-system gnu-build-system)
985 `(#:tests? #f ;no upstream tests
988 (string-append "PREFIX=" (assoc-ref %outputs "out"))
989 (string-append "LTERMCAP=-lncurses")
990 (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses")
993 (modify-phases %standard-phases
994 (delete 'configure)))) ;no configure script
996 `(("ncurses" ,ncurses)))
997 (home-page "https://devel.ringlet.net/editors/hexer/")
998 (synopsis "Multi buffer editor for binary files with vi-like interface")
999 (description "Hexer is a multi-buffer editor for binary files for Unix-like
1000 systems that displays its buffer(s) as a hex dump. The user interface is kept
1002 (license license:bsd-3)))