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 ng0 <ng0@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>
14 ;;; This file is part of GNU Guix.
16 ;;; GNU Guix is free software; you can redistribute it and/or modify it
17 ;;; under the terms of the GNU General Public License as published by
18 ;;; the Free Software Foundation; either version 3 of the License, or (at
19 ;;; your option) any later version.
21 ;;; GNU Guix is distributed in the hope that it will be useful, but
22 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 ;;; GNU General Public License for more details.
26 ;;; You should have received a copy of the GNU General Public License
27 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
29 (define-module (gnu packages text-editors)
30 #:use-module (guix packages)
31 #:use-module (guix download)
32 #:use-module (guix git-download)
33 #:use-module (guix utils)
34 #:use-module (guix build-system cmake)
35 #:use-module (guix build-system gnu)
36 #:use-module (guix build-system cmake)
37 #:use-module (guix build-system glib-or-gtk)
38 #:use-module (guix build-system python)
39 #:use-module ((guix licenses) #:prefix license:)
40 #:use-module (gnu packages)
41 #:use-module (gnu packages aspell)
42 #:use-module (gnu packages assembly)
43 #:use-module (gnu packages autotools)
44 #:use-module (gnu packages boost)
45 #:use-module (gnu packages documentation)
46 #:use-module (gnu packages fontutils)
47 #:use-module (gnu packages gcc)
48 #:use-module (gnu packages gettext)
49 #:use-module (gnu packages glib)
50 #:use-module (gnu packages gtk)
51 #:use-module (gnu packages guile)
52 #:use-module (gnu packages haskell-xyz)
53 #:use-module (gnu packages libbsd)
54 #:use-module (gnu packages libreoffice)
55 #:use-module (gnu packages llvm)
56 #:use-module (gnu packages lua)
57 #:use-module (gnu packages ncurses)
58 #:use-module (gnu packages pcre)
59 #:use-module (gnu packages perl)
60 #:use-module (gnu packages pkg-config)
61 #:use-module (gnu packages python)
62 #:use-module (gnu packages python-xyz)
63 #:use-module (gnu packages qt)
64 #:use-module (gnu packages regex)
65 #:use-module (gnu packages ruby)
66 #:use-module (gnu packages terminals)
67 #:use-module (gnu packages texinfo)
68 #:use-module (gnu packages version-control)
69 #:use-module (gnu packages xml)
70 #:use-module (gnu packages xorg))
78 (uri (string-append "https://github.com/martanne/vis/releases"
80 "/vis-v" version ".tar.gz"))
83 "0aw35n8xk7ir84ckvczc6yshj9ynishrlz0qlv4yc1afbra1gxmn"))))
84 (build-system gnu-build-system)
86 `(#:test-target "test"
87 #:tests? #f ; no releases; snapshots are missing tests
89 (modify-phases %standard-phases
90 (add-after 'install 'wrap-binary
91 (lambda* (#:key inputs outputs #:allow-other-keys)
92 (let* ((out (assoc-ref outputs "out"))
93 (lpeg (assoc-ref inputs "lua-lpeg"))
94 (lua-version ,(version-major+minor (package-version lua)))
95 (LUA_PATH (string-append lpeg "/share/lua/"
96 lua-version "/?.lua"))
97 (LUA_CPATH (string-append lpeg "/lib/lua/"
98 lua-version "/?.so")))
99 (wrap-program (string-append out "/bin/vis")
100 `("LUA_PATH" ":" prefix (,LUA_PATH))
101 `("LUA_CPATH" ":" prefix (,LUA_CPATH)))
104 (list (search-path-specification
105 (variable "VIS_PATH")
106 (files '("share/vis")))))
107 (inputs `(("lua" ,lua)
109 ("libtermkey" ,libtermkey)
110 ("lua-lpeg" ,lua-lpeg)
112 (synopsis "Vim-like text editor")
114 "Vis aims to be a modern, legacy free, simple yet efficient vim-like text
115 editor. It extends vim's modal editing with built-in support for multiple
116 cursors/selections and combines it with sam's structural regular expression
117 based command language.")
118 (home-page "https://github.com/martanne/vis")
119 (license (list license:isc ; Main distribution.
120 license:public-domain ; map.[ch]
121 license:expat)))) ; lexers and libutf.[ch]
123 (define-public kakoune
126 (version "2020.01.16")
130 (uri (string-append "https://github.com/mawww/kakoune/"
131 "releases/download/v" version "/"
132 "kakoune-" version ".tar.bz2"))
134 (base32 "1bhd990gywdwdhxc5dn83wwj418c5cw1ndqycf7k0a02kxlg3550"))))
135 (build-system gnu-build-system)
138 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
140 (modify-phases %standard-phases
141 (add-after 'unpack 'patch-source
143 ;; kakoune uses confstr with _CS_PATH to find out where to find
144 ;; a posix shell, but this doesn't work in the build
145 ;; environment. This substitution just replaces that result
146 ;; with the "sh" path.
147 (substitute* "src/shell_manager.cc"
148 (("if \\(m_shell.empty\\(\\)\\)" line)
149 (string-append "m_shell = \"" (which "sh")
152 (delete 'configure) ; no configure script
153 ;; kakoune requires us to be in the src/ directory to build
154 (add-before 'build 'chdir
155 (lambda _ (chdir "src") #t)))))
157 `(("asciidoc" ,asciidoc)
158 ("pkg-config" ,pkg-config)
161 `(("ncurses" ,ncurses)))
162 (synopsis "Vim-inspired code editor")
164 "Kakoune is a code editor heavily inspired by Vim, as such most of its
165 commands are similar to Vi's ones, and it shares Vi's \"keystrokes as a text
166 editing language\" model. Kakoune has a strong focus on interactivity, most
167 commands provide immediate and incremental results, while still being
168 competitive (as in keystroke count) with Vim.")
169 (home-page "https://kakoune.org/")
170 (license license:unlicense)))
179 (uri (string-append "https://sourceforge.net/projects/joe-editor/"
180 "files/JOE sources/joe-" version "/"
181 "joe-" version ".tar.gz"))
184 "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9"))))
185 (build-system gnu-build-system)
186 (inputs `(("ncurses" ,ncurses)))
187 (home-page "http://joe-editor.sourceforge.net/")
188 (synopsis "Console screen editor")
190 "JOE is a powerful console screen editor with a \"mode-less\" user
191 interface similar to many user-friendly editors. JOE has some of the key
192 bindings and many of the powerful features of GNU Emacs.")
193 (license license:gpl3+)))
195 (define-public jucipp
199 (home-page "https://gitlab.com/cppit/jucipp")
202 (uri (git-reference (url home-page)
203 (commit (string-append "v" version))
204 ;; Two submodules are required which are
205 ;; developed alongside JuCi++ and difficult
206 ;; to package separately.
208 (file-name (git-file-name name version))
210 (base32 "0v7fmsya2zn1xx59bkv4cbyinmcnv52hm4j40nbfwalcks631xrr"))))
211 (build-system cmake-build-system)
213 `(#:configure-flags '("-DBUILD_TESTING=ON"
215 ;; These arguments are here to facilitate an "in-source"
216 ;; build using "./build" instead of the default "../build".
217 ;; The test suite expects that to be the case.
220 #:phases (modify-phases %standard-phases
221 (add-before 'configure 'enter-build-directory
227 ;; This phase is necessary to fix a test failure, see
228 ;; <https://gitlab.com/cppit/jucipp/-/issues/423>.
229 (add-after 'unpack 'add-reference-to-clang-internal-header
230 (lambda* (#:key inputs #:allow-other-keys)
231 (substitute* "src/compile_commands.cc"
232 ((".*-I/usr/lib/clang.*" all)
233 (string-append "arguments.emplace_back(\"-I"
234 (assoc-ref inputs "libclang")
236 ,@(list (package-version clang))
240 (add-after 'unpack 'patch-tiny-process-library
242 (with-directory-excursion "lib/tiny-process-library"
243 (substitute* '("process_unix.cpp"
245 (("/bin/sh") (which "sh"))))
247 (add-after 'unpack 'disable-git-test
249 (substitute* "tests/CMakeLists.txt"
250 ;; Disable the git test, as it requires the full checkout.
251 (("add_test\\(git_test.*\\)") ""))
253 (add-before 'check 'pre-check
254 (lambda* (#:key inputs #:allow-other-keys)
255 ;; Tests do not expect HOME to be empty.
256 (setenv "HOME" "/etc")
258 ;; Most tests require an X server.
259 (let ((xorg-server (assoc-ref inputs "xorg-server"))
261 (setenv "DISPLAY" display)
262 (system (string-append xorg-server "/bin/Xvfb "
266 `(("pkg-config" ,pkg-config)
267 ("xorg-server" ,xorg-server-for-tests)))
272 ("gtksourceviewmm" ,gtksourceviewmm)
274 ("libgit2" ,libgit2)))
275 (synopsis "Lightweight C++ IDE")
277 "juCi++ is a small @dfn{IDE} (Integrated Development Environment)
278 designed especially towards libclang with speed, stability, and ease of use
281 It supports autocompletion, on-the-fly warnings and errors, syntax
282 highlighting, and integrates with Git as well as the CMake and Meson build
284 (license license:expat)))
286 (define-public leafpad
292 (uri (string-append "mirror://savannah/"
293 "leafpad/leafpad-" version ".tar.gz"))
296 "0b0az2wvqgvam7w0ns1j8xp2llslm1rx6h7zcsy06a7j0yp257cm"))))
297 (build-system glib-or-gtk-build-system)
299 `(("intltool" ,intltool)
300 ("pkg-config" ,pkg-config)))
303 (home-page "http://tarot.freeshell.org/leafpad/")
304 (synopsis "GTK+ based text editor")
305 (description "Leafpad is a GTK+ text editor that emphasizes simplicity. As
306 development focuses on keeping weight down to a minimum, only the most essential
307 features are implemented in the editor. Leafpad is simple to use, is easily
308 compiled, requires few libraries, and starts up quickly. ")
309 (license license:gpl2+)))
317 (uri (string-append "https://sites.google.com/site/e3editor/Home/"
318 "e3-" version ".tgz"))
321 "0919kadkas020maqq37852isnzp053q2fnws2zh3mz81d1jiviak"))
322 (modules '((guix build utils)))
324 ;; Remove pre-built binaries.
326 (delete-file-recursively "bin")
328 (build-system gnu-build-system)
331 #:make-flags (list (string-append "PREFIX="
332 (assoc-ref %outputs "out")))
333 #:phases (modify-phases %standard-phases
334 (delete 'configure))))
337 (home-page "https://sites.google.com/site/e3editor/")
338 (synopsis "Tiny text editor written in assembly")
340 "e3 is a micro text editor with an executable code size between 3800 and
341 35000 bytes. Except for ``syntax highlighting'', the e3 binary supports all
342 of the basic functions one expects plus built in arithmetic calculations.
343 UTF-8 coding of unicode characters is supported as well. e3 can use
344 Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings. e3 can be used on
345 16, 32, and 64-bit CPUs.")
346 (supported-systems '("x86_64-linux" "i686-linux"))
347 (license license:gpl2+)))
356 (url "https://github.com/hboetes/mg")
358 (file-name (git-file-name name version))
361 "14vrm8lvwksf697sqks7xfd1xaqjlqjc9afjk33sksq5p27wr203"))
362 (modules '((guix build utils)))
364 (substitute* "GNUmakefile"
367 (build-system gnu-build-system)
369 `(("pkg-config" ,pkg-config)))
372 ("ncurses" ,ncurses)))
374 ;; No test suite available.
376 #:make-flags (list (string-append "prefix=" %output)
378 #:phases (modify-phases %standard-phases
379 (delete 'configure) ; no configure script
380 (add-before 'build 'correct-location-of-difftool
382 (substitute* "buffer.c"
386 (add-before 'install 'patch-tutorial-location
387 (lambda* (#:key outputs #:allow-other-keys)
389 (("/usr") (assoc-ref outputs "out")))
391 (add-after 'install 'install-tutorial
392 (lambda* (#:key outputs #:allow-other-keys)
393 (let* ((out (assoc-ref outputs "out"))
394 (doc (string-append out "/share/doc/mg")))
395 (install-file "tutorial" doc)
397 (home-page "https://homepage.boetes.org/software/mg/")
398 (synopsis "Microscopic GNU Emacs clone")
400 "Mg (@command{mg}) is a GNU Emacs style editor, with which it is
401 \"broadly\" compatible. This is a portable version of the mg maintained by the
403 (license license:public-domain)))
405 (define-public qemacs
412 (uri (string-append "https://bellard.org/qemacs/"
413 "qemacs-" version ".tar.gz"))
415 (base32 "156z4wpj49i6j388yjird5qvrph7hz0grb4r44l4jf3q8imadyrg"))))
416 (build-system gnu-build-system)
418 `(#:tests? #f ;no test
420 (modify-phases %standard-phases
421 (add-before 'build 'build-qhtml
422 ;; Build fails without first creating qHTML library.
423 (lambda _ (invoke "make" "-C" "libqhtml")))
424 (add-before 'install 'fix-man-pages-directory
425 ;; Install in $out/share/man instead of $out/man.
427 (substitute* "Makefile"
428 (("/man/man1" all) (string-append "/share" all)))
430 (add-before 'install 'create-directories
431 ;; Ensure directories exist before installing files.
432 (lambda* (#:key outputs #:allow-other-keys)
433 (let ((out (assoc-ref outputs "out")))
434 (for-each (lambda (d) (mkdir-p (string-append out d)))
435 '("/bin" "/share/man/man1" "/share/qe"))
437 (add-after 'install 'install-extra-documentation
438 ;; Install sample configuration file, Info, and HTML manual.
439 (lambda* (#:key outputs #:allow-other-keys)
440 (let* ((share (string-append (assoc-ref outputs "out") "/share"))
441 (doc (string-append share "/doc/" ,name "-" ,version))
442 (html (string-append share "/html"))
443 (info (string-append share "/info"))
444 (makeinfo (string-append (assoc-ref %build-inputs "texinfo")
446 ;; First fix Texinfo documentation, create appropriate
447 ;; directories, then generate Info and HTML files there.
448 (substitute* "qe-doc.texi"
449 (("^M-([{}])" _ bracket) (string-append "M-@" bracket)))
450 (for-each (lambda (d) (mkdir-p d)) (list html info))
451 (invoke makeinfo "qe-doc.texi" "-o" info)
452 (invoke makeinfo "qe-doc.texi" "--html" "--no-split" "-o" html)
453 ;; Install sample configuration file.
454 (install-file "config.eg" doc)
457 `(("texinfo" ,texinfo)))
462 (home-page "https://bellard.org/qemacs/")
463 (synopsis "Small but powerful text editor")
464 (description "QEmacs (for Quick Emacs) is a very small but
465 powerful editor. It has features that even big editors lack:
469 @item Full screen editor with an Emacs look and feel with all Emacs
470 common features: multi-buffer, multi-window, command mode, universal
471 argument, keyboard macros, config file with C-like syntax, minibuffer
472 with completion and history.
474 @item Can edit files of hundreds of Megabytes without being slow by
475 using a highly optimized internal representation and by mmaping the
478 @item Full Unicode support, including multi charset handling (8859-x,
479 UTF8, SJIS, EUC-JP, ...) and bidirectional editing respecting the
480 Unicode bidi algorithm. Arabic and Indic scripts handling (in
483 @item WYSIWYG HTML/XML/CSS2 mode graphical editing. Also supports
484 Lynx like rendering on VT100 terminals.
486 @item WYSIWYG DocBook mode based on XML/CSS2 renderer.
488 @item C mode: coloring with immediate update. Emacs like auto-indent.
490 @item Shell mode: colorized VT100 emulation so that your shell work
491 exactly as you expect. Compile mode with next/prev error.
493 @item Input methods for most languages, including Chinese (input
494 methods come from the Yudit editor).
496 @item Hexadecimal editing mode with insertion and block commands.
497 Unicode hexa editing is also supported.
499 @item Works on any VT100 terminals without termcap. UTF8 VT100
500 support included with double width glyphs.
502 @item X11 support. Support multiple proportional fonts at the same
503 time (as XEmacs). X Input methods supported. Xft extension supported
504 for anti aliased font display.
506 @item Small! Full version (including HTML/XML/CSS2/DocBook rendering
507 and all charsets): 200KB big. Basic version (without bidir/unicode
508 scripts/input/X11/C/Shell/HTML/Dired): 49KB.
510 (license license:lgpl2.1+)))
512 (define-public ghostwriter
519 (url "https://github.com/wereturtle/ghostwriter.git")
520 (commit (string-append "v" version))))
521 (file-name (git-file-name name version))
524 "13yn82m1l2pq93wbl569a2lzpc3sn8a8g30hsgdch1l9xlmhwran"))))
525 (build-system gnu-build-system)
527 `(("pkg-config" ,pkg-config)
528 ("qttools" ,qttools))) ; for lrelease
530 `(("hunspell" ,hunspell)
532 ("qtdeclarative" ,qtdeclarative)
533 ("qtmultimedia" ,qtmultimedia)
534 ("qtquickcontrols" ,qtquickcontrols)
536 ("qtwebchannel" ,qtwebchannel)))
537 (propagated-inputs ; To get native-search-path
538 `(("qtwebengine" ,qtwebengine)))
541 (modify-phases %standard-phases
543 (lambda* (#:key outputs #:allow-other-keys)
544 (let ((out (assoc-ref outputs "out")))
545 (invoke "qmake" (string-append "PREFIX=" out)))))
546 (add-after 'configure 'create-translations
548 ;; `lrelease` will not overwrite, so delete existing .qm files
549 (for-each delete-file (find-files "translations" ".*\\.qm"))
550 (apply invoke "lrelease" (find-files "translations" ".*\\.ts"))))
551 ;; Ensure that icons are found at runtime.
552 (add-after 'install 'wrap-executable
553 (lambda* (#:key inputs outputs #:allow-other-keys)
554 (let ((out (assoc-ref outputs "out")))
555 (wrap-program (string-append out "/bin/ghostwriter")
556 `("QT_PLUGIN_PATH" ":" prefix
557 ,(map (lambda (label)
558 (string-append (assoc-ref inputs label)
559 "/lib/qt5/plugins/"))
560 '("qtsvg" "qtmultimedia"))))))))))
561 (home-page "https://wereturtle.github.io/ghostwriter/")
562 (synopsis "Write without distractions")
564 "@code{ghostwriter} provides a relaxing, distraction-free writing
565 environment with Markdown markup.")
566 (license license:gpl3+))) ; icons/* under CC-BY-SA3
568 (define-public manuskript
576 (url "https://github.com/olivierkes/manuskript.git")
578 (file-name (git-file-name name version))
580 (base32 "1l6l9k6k69yv8xqpll0zv9cwdqqg4zvxy90l6sx5nv2yywh5crla"))))
581 (build-system python-build-system)
583 `(#:tests? #f ;no test
585 (modify-phases %standard-phases
589 (lambda* (#:key outputs #:allow-other-keys)
590 (let* ((out (assoc-ref outputs "out"))
591 (share (string-append out "/share/manuskript")))
596 (let ((destination (string-append share "/" d)))
597 (mkdir-p destination)
598 (copy-recursively d destination)))
599 '("bin" "i18n" "icons" "libs" "manuskript" "resources"))
600 ;; Install documentation.
601 (let ((doc (string-append out
602 "/doc/manuskript-" ,version
603 "/sample-projects")))
605 (copy-recursively "sample-projects" doc))
606 ;; Wrap executable in "$out/share/manuskript/bin" and
607 ;; link to it from "$out/bin".
608 (let ((bin (string-append out "/bin"))
609 (executable (string-append share "/bin/manuskript")))
610 (wrap-program executable
611 (list "PYTHONPATH" 'prefix (list (getenv "PYTHONPATH"))))
613 (with-directory-excursion bin
614 (symlink (string-append share "/bin/manuskript")
616 ;; Install icons and create .desktop file.
617 (let ((apps (string-append out "/share/applications"))
618 (icons-dir (string-append out "/share/pixmaps")))
619 (install-file "icons/Manuskript/manuskript.svg" icons-dir)
621 (with-output-to-file (string-append apps "/manuskript.desktop")
626 MimeType=application/x-manuskript-book;~@
627 Exec=~a/bin/manuskript %f~@
628 Comment=Tool for writers~@
629 Comment[es]=Herramienta para escritores/as~@
630 Keywords=manuskript;office;write;edit;novel;text;msk~@
634 Categories=Office;WordProcessor;~%"
638 `(("ghc-pandoc" ,ghc-pandoc)
639 ("python-lxml" ,python-lxml)
640 ("python-markdown" ,python-markdown)
641 ("python-pyqt" ,python-pyqt)
643 (home-page "http://www.theologeek.ch/manuskript/")
644 (synopsis "Tool for writers")
645 (description "Manuskript provides a rich environment to help
646 writers create their first draft and then further refine and edit
647 their masterpiece. With Manuskript you can:
650 @item Grow your premise from one sentence, to a paragraph, to a full
652 @item Create characters,
653 @item Conceive plots,
654 @item Construct outlines (Outline mode and/or Index cards),
655 @item Write with focus (Distraction free mode),
658 @item Edit and re-organize chapters and scenes,
659 @item View Story line,
660 @item Compose with fiction or non-fiction templates and writing modes,
661 @item Import and export document formats such as HTML, ePub,
662 OpenDocument, DocX, and more.
665 Additionally Manuskript can help in many more ways with a spell
666 checker, markdown highlighter, frequency analyzer, and automatic save
667 in plain text file format.")
668 (license license:gpl3+)))
670 (define-public editorconfig-core-c
672 (name "editorconfig-core-c")
678 (url "https://github.com/editorconfig/editorconfig-core-c.git")
679 (commit (string-append "v" version))))
680 (file-name (git-file-name name version))
683 "0jkc69r4jwn4rih6h6cqvgljjc3ff49cxj8286mi515aczr48cm1"))))
684 (build-system cmake-build-system)
687 (modify-phases %standard-phases
688 (add-after 'unpack 'insert-tests
689 (lambda* (#:key inputs #:allow-other-keys)
690 (let ((tests (assoc-ref inputs "tests")))
691 (copy-recursively tests "tests"))
697 (url "https://github.com/editorconfig/editorconfig-core-test")
698 (commit "6ea1d8ece62cac9cf72c79dce4879b046abe1fe7"))) ; matches version
699 (file-name (git-file-name "editorconfig-core-test" version))
702 "1sf6910idnd4bgzbj8w8f9ldsbkaqa0lh6syymwy3hfqda63acj7"))))))
705 (home-page "https://editorconfig.org/")
706 (synopsis "EditorConfig core library written in C")
707 (description "EditorConfig makes it easy to maintain the correct coding
708 style when switching between different text editors and between different
709 projects. The EditorConfig project maintains a file format and plugins for
710 various text editors which allow this file format to be read and used by those
712 (license license:bsd-2)))
714 (define-public texmacs
721 (uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/"
722 "source/TeXmacs-" version "-src.tar.gz"))
724 (base32 "12bp0f34izzqimz49lfpgf4lyz3h45s9xbmk8v6zsawdjki76alg"))
725 (modules '((guix build utils)))
728 (delete-file-recursively "3rdparty")
730 (build-system gnu-build-system)
732 `(("pkg-config" ,pkg-config)))
734 `(("freetype" ,freetype)
737 ("python" ,python-wrapper)
740 `(#:tests? #f ; no check target
742 (modify-phases %standard-phases
743 (add-before 'configure 'gzip-flags
745 (substitute* "Makefile.in"
746 (("^GZIP = gzip -f") "GZIP = gzip -f -n")))))))
747 (synopsis "Editing platform with special features for scientists")
749 "GNU TeXmacs is a text editing platform which is specialized for
750 scientists. It is ideal for editing structured documents with different
751 types of content. It has robust support for mathematical formulas and plots.
752 It can also act as an interface to external mathematical programs such as R
753 and Octave. TeXmacs is completely extensible via Guile.")
754 (license license:gpl3+)
755 (home-page "https://www.texmacs.org/tmweb/home/welcome.en.html")))
757 (define-public scintilla
764 (uri (let ((v (apply string-append (string-split version #\.))))
765 (string-append "https://www.scintilla.org/scintilla" v ".tgz")))
767 (base32 "0d8ssl0d8r6bslbzd507l9c5g8mwn1zriak3fnf85936pdmkhq9h"))))
768 (build-system gnu-build-system)
770 `(#:make-flags (list "GTK3=1" "CC=gcc" "-Cgtk")
771 #:tests? #f ;require un-packaged Pyside
773 (modify-phases %standard-phases
774 (delete 'configure) ;no configure script
775 (add-after 'unpack 'build-shared-library
777 (substitute* "gtk/makefile"
778 (("scintilla\\.a") "libscintilla.so")
779 (("\\$\\(AR\\) \\$\\(ARFLAGS\\) \\$@ \\$\\^")
780 "$(CC) -shared $^ -o $@")
781 (("\\$\\(RANLIB\\) \\$@") ""))
784 (lambda* (#:key outputs #:allow-other-keys)
785 (let* ((out (assoc-ref outputs "out"))
786 (lib (string-append out "/lib"))
787 (include (string-append out "/include")))
788 (install-file "bin/libscintilla.so" lib)
789 (for-each (lambda (f) (install-file f include))
790 (find-files "include/" "."))
793 `(("pkg-config" ,pkg-config)
794 ("python" ,python-wrapper)))
797 (home-page "https://www.scintilla.org/")
798 (synopsis "Code editor for GTK+")
799 (description "Scintilla is a source code editing component for
800 GTK+. It has the usual features found in text editing components, as
801 well as some that are especially useful for editing and debugging
802 source code; these include support for syntax styling, error
803 indicators, code completion and call tips. Styling choices are more
804 open than with many editors: Scintilla lets you use proportional
805 fonts, bold and italics, multiple foreground and background colours,
806 and multiple fonts.")
807 (license license:hpnd)))
815 (uri (string-append "https://download.geany.org/"
816 "geany-" version ".tar.bz2"))
819 "0gnm17cr4rf3pmkf0axz4a0fxwnvp55ji0q0lzy88yqbshyxv14i"))
820 (modules '((guix build utils)))
822 (delete-file-recursively "scintilla")
824 (build-system gnu-build-system)
826 `(("autoconf" ,autoconf)
827 ("automake" ,automake)
830 ("intltool" ,intltool)
832 ("pkg-config" ,pkg-config)
833 ("python-docutils" ,python-docutils))) ;for rst2html
836 ("scintilla" ,scintilla)))
839 (modify-phases %standard-phases
840 (add-after 'unpack 'use-scintilla-shared-library
841 (lambda* (#:key inputs #:allow-other-keys)
842 (substitute* "configure.ac"
843 (("scintilla/Makefile") "")
844 (("scintilla/include/Makefile") ""))
845 (substitute* "Makefile.am"
847 (substitute* "src/Makefile.am"
848 (("\\$\\(top_builddir\\)/scintilla/libscintilla.la") "")
849 (("geany_LDFLAGS =" all) (string-append all " -lscintilla")))
850 (substitute* "doc/Makefile.am"
851 (("\\$\\(INSTALL_DATA\\) \\$\\(top_srcdir\\)/scintilla/License.txt \\$\\(DOCDIR\\)/ScintillaLicense.txt") ""))
852 (substitute* "tests/Makefile.am"
853 (("AM_LDFLAGS =" all) (string-append all " -lscintilla")))
854 (for-each delete-file (list "autogen.sh" "configure" "Makefile.in"))
856 (home-page "https://www.geany.org")
857 (synopsis "Fast and lightweight IDE")
858 (description "Geany is a small and fast Integrated Development
859 Environment (IDE) that only has a few dependencies on other packages and is as
860 independent as possible from special desktop environments like KDE or GNOME.
862 The basic features of Geany are:
864 @item syntax highlighting
865 @item code completion
866 @item auto completion of often constructed constructs like if, for and while
867 @item auto completion of XML and HTML tags
870 @item many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal
872 @item embedded terminal emulation
873 @item extensibility through plugins
875 (license license:gpl2+)))
880 ;; Stable release is 1.8. However, this development version
881 ;; introduces support for UTF-8.
885 (uri (string-append "http://www.moria.de/~michael/fe/"
886 "fe-" version ".tar.gz"))
889 "1hwws7si1752z6hp61zxznvgsb6846lp8zl1hn5ddhsbafwalwb9"))))
890 (build-system gnu-build-system)
892 `(#:tests? #f ;no test
893 ;; Sendmail is only used to send a crash log. Disable the
894 ;; feature since it is (1) undocumented (2) not very useful.
895 #:configure-flags (list "--disable-sendmail")
897 (modify-phases %standard-phases
898 (add-after 'install 'install-doc
899 (lambda* (#:key outputs #:allow-other-keys)
900 (let* ((out (assoc-ref outputs "out"))
901 (doc (string-append out "/share/doc/" ,name "-" ,version)))
902 (for-each (lambda (f) (install-file f doc))
903 '("fe.doc" "fe.html" "fe.ps" "feref.ps" "README"))
906 `(("gettext" ,gettext-minimal)))
908 `(("ncurses" ,ncurses)))
909 (home-page "http://www.moria.de/~michael/fe/")
910 (synopsis "Small folding editor")
911 (description "Fe is a small folding editor. It folds
912 arbitrary text regions; it is not bound to syntactic units.
914 Fe has no configuration or extension language and requires no setup.
915 Its user interface is emacs-like and it has menus for the very most
916 important functions to help beginners. Further there is a reference
920 @item Regions and Emacs-like kill ring
921 @item Incremental search
922 @item Keyboard macros
923 @item Editing binary files
924 @item Multiple windows and views
925 @item Compose function for Latin 1 characters
927 (license license:gpl2+)))
936 (url "https://github.com/vigna/ne.git")
938 (file-name (git-file-name name version))
941 "0h6d08cnwrk96ss83i9bragwwanph6x54sm3ak1z81146dsqsiif"))))
942 (build-system gnu-build-system)
945 ("texinfo" ,texinfo)))
947 `(("ncurses" ,ncurses)))
952 (string-append "PREFIX=" (assoc-ref %outputs "out"))
953 (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses")
956 (modify-phases %standard-phases
959 (substitute* "src/makefile"
960 (("-lcurses") "-lncurses"))
962 (home-page "http://ne.di.unimi.it/")
963 (synopsis "Text editor with menu bar")
964 (description "This package provides a modeless text editor with menu bar.
965 It supports syntax highlighting, regular expressions, configurable menus,
966 keybindings, autocomplete and unlimited undo. It can pipe a marked block
967 of text through any command line filter. It can also open very large binary
968 files. It was originally developed on the Amiga 3000T.")
969 (license license:gpl3+)))