gnu: r-squarem: Update home page and use HTTPS.
[jackhill/guix/guix.git] / gnu / packages / text-editors.scm
CommitLineData
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>
bc111d39 4;;; Copyright © 2017, 2018 Eric Bavier <bavier@member.fsf.org>
0bf11648 5;;; Copyright © 2017 Feng Shu <tumashu@163.com>
47956fa0 6;;; Copyright © 2017 ng0 <ng0@n0.is>
bcd757fd 7;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.org>
77100119 8;;; Copyright © 2017, 2018, 2019, 2020 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>
1fffba66 11;;; Copyright © 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
a2c1dcea
JMSG
12;;;
13;;; This file is part of GNU Guix.
14;;;
15;;; GNU Guix is free software; you can redistribute it and/or modify it
16;;; under the terms of the GNU General Public License as published by
17;;; the Free Software Foundation; either version 3 of the License, or (at
18;;; your option) any later version.
19;;;
20;;; GNU Guix is distributed in the hope that it will be useful, but
21;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23;;; GNU General Public License for more details.
24;;;
25;;; You should have received a copy of the GNU General Public License
26;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
27
28(define-module (gnu packages text-editors)
29 #:use-module (guix packages)
30 #:use-module (guix download)
5613ea79 31 #:use-module (guix git-download)
a2c1dcea
JMSG
32 #:use-module (guix utils)
33 #:use-module (guix build-system gnu)
2238211a 34 #:use-module (guix build-system cmake)
4f038621 35 #:use-module (guix build-system glib-or-gtk)
1fffba66 36 #:use-module (guix build-system python)
a2c1dcea
JMSG
37 #:use-module ((guix licenses) #:prefix license:)
38 #:use-module (gnu packages)
3312fda0 39 #:use-module (gnu packages assembly)
2363ed01 40 #:use-module (gnu packages autotools)
5613ea79
CZ
41 #:use-module (gnu packages boost)
42 #:use-module (gnu packages documentation)
75a137da 43 #:use-module (gnu packages fontutils)
5613ea79 44 #:use-module (gnu packages gcc)
2207d522 45 #:use-module (gnu packages gettext)
0bf11648
FS
46 #:use-module (gnu packages glib)
47 #:use-module (gnu packages gtk)
75a137da 48 #:use-module (gnu packages guile)
1fffba66 49 #:use-module (gnu packages haskell-xyz)
bcd757fd 50 #:use-module (gnu packages libbsd)
04918a00 51 #:use-module (gnu packages libreoffice)
a2c1dcea
JMSG
52 #:use-module (gnu packages lua)
53 #:use-module (gnu packages ncurses)
2238211a 54 #:use-module (gnu packages pcre)
75a137da 55 #:use-module (gnu packages perl)
0bf11648 56 #:use-module (gnu packages pkg-config)
75a137da 57 #:use-module (gnu packages python)
2363ed01 58 #:use-module (gnu packages python-xyz)
04918a00 59 #:use-module (gnu packages qt)
852ba10a 60 #:use-module (gnu packages regex)
5613ea79 61 #:use-module (gnu packages ruby)
264ccbb3 62 #:use-module (gnu packages terminals)
a78364e9 63 #:use-module (gnu packages texinfo)
fb85b967
NG
64 #:use-module (gnu packages xml)
65 #:use-module (gnu packages xorg))
a2c1dcea
JMSG
66
67(define-public vis
68 (package
69 (name "vis")
dadc8610 70 (version "0.5")
a2c1dcea
JMSG
71 (source (origin
72 (method url-fetch)
7ec38295
EF
73 (uri (string-append "https://github.com/martanne/vis/releases"
74 "/download/v" version
75 "/vis-v" version ".tar.gz"))
a2c1dcea 76 (sha256
852ba10a 77 (base32
7ec38295 78 "0aw35n8xk7ir84ckvczc6yshj9ynishrlz0qlv4yc1afbra1gxmn"))))
a2c1dcea
JMSG
79 (build-system gnu-build-system)
80 (arguments
852ba10a
TGR
81 `(#:test-target "test"
82 #:tests? #f ; no releases; snapshots are missing tests
a2c1dcea
JMSG
83 #:phases
84 (modify-phases %standard-phases
85 (add-after 'install 'wrap-binary
86 (lambda* (#:key inputs outputs #:allow-other-keys)
87 (let* ((out (assoc-ref outputs "out"))
88 (lpeg (assoc-ref inputs "lua-lpeg"))
89 (lua-version ,(version-major+minor (package-version lua)))
90 (LUA_PATH (string-append lpeg "/share/lua/"
91 lua-version "/?.lua"))
92 (LUA_CPATH (string-append lpeg "/lib/lua/"
93 lua-version "/?.so")))
94 (wrap-program (string-append out "/bin/vis")
95 `("LUA_PATH" ":" prefix (,LUA_PATH))
96 `("LUA_CPATH" ":" prefix (,LUA_CPATH)))
97 #t))))))
98 (native-search-paths
99 (list (search-path-specification
100 (variable "VIS_PATH")
101 (files '("share/vis")))))
c695fb76
TGR
102 (inputs `(("lua" ,lua)
103 ("ncurses" ,ncurses)
104 ("libtermkey" ,libtermkey)
105 ("lua-lpeg" ,lua-lpeg)
852ba10a 106 ("tre" ,tre)))
a2c1dcea
JMSG
107 (synopsis "Vim-like text editor")
108 (description
109 "Vis aims to be a modern, legacy free, simple yet efficient vim-like text
110editor. It extends vim's modal editing with built-in support for multiple
111cursors/selections and combines it with sam's structural regular expression
112based command language.")
113 (home-page "https://github.com/martanne/vis")
114 (license (list license:isc ; Main distribution.
115 license:public-domain ; map.[ch]
116 license:expat)))) ; lexers and libutf.[ch]
5613ea79
CZ
117
118(define-public kakoune
fbe8ebec
TGR
119 (package
120 (name "kakoune")
be0a613c 121 (version "2019.12.10")
fbe8ebec
TGR
122 (source
123 (origin
124 (method url-fetch)
125 (uri (string-append "https://github.com/mawww/kakoune/"
126 "releases/download/v" version "/"
a1cb6928 127 "kakoune-" version ".tar.bz2"))
fbe8ebec 128 (sha256
be0a613c 129 (base32 "1y1gzax2dl7flh676k0rl1vacv10j7p5krkmb67b0afbrql8vbb6"))))
fbe8ebec
TGR
130 (build-system gnu-build-system)
131 (arguments
132 `(#:make-flags
133 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
134 #:phases
135 (modify-phases %standard-phases
136 (add-after 'unpack 'patch-source
137 (lambda _
138 ;; kakoune uses confstr with _CS_PATH to find out where to find
139 ;; a posix shell, but this doesn't work in the build
140 ;; environment. This substitution just replaces that result
141 ;; with the "sh" path.
142 (substitute* "src/shell_manager.cc"
143 (("if \\(m_shell.empty\\(\\)\\)" line)
144 (string-append "m_shell = \"" (which "sh")
145 "\";\n " line)))
146 #t))
147 (delete 'configure) ; no configure script
148 ;; kakoune requires us to be in the src/ directory to build
149 (add-before 'build 'chdir
150 (lambda _ (chdir "src") #t)))))
151 (native-inputs
152 `(("asciidoc" ,asciidoc)
153 ("pkg-config" ,pkg-config)
154 ("ruby" ,ruby)))
155 (inputs
73eacca8 156 `(("ncurses" ,ncurses)))
fbe8ebec
TGR
157 (synopsis "Vim-inspired code editor")
158 (description
159 "Kakoune is a code editor heavily inspired by Vim, as such most of its
5613ea79
CZ
160commands are similar to Vi's ones, and it shares Vi's \"keystrokes as a text
161editing language\" model. Kakoune has a strong focus on interactivity, most
162commands provide immediate and incremental results, while still being
163competitive (as in keystroke count) with Vim.")
27405497 164 (home-page "https://kakoune.org/")
fbe8ebec 165 (license license:unlicense)))
f255a6db
EB
166
167(define-public joe
168 (package
169 (name "joe")
bc111d39 170 (version "4.6")
f255a6db
EB
171 (source
172 (origin
173 (method url-fetch)
174 (uri (string-append "https://sourceforge.net/projects/joe-editor/"
175 "files/JOE sources/joe-" version "/"
176 "joe-" version ".tar.gz"))
177 (sha256
178 (base32
bc111d39 179 "1pmr598xxxm9j9dl93kq4dv36zyw0q2dh6d7x07hf134y9hhlnj9"))))
f255a6db
EB
180 (build-system gnu-build-system)
181 (inputs `(("ncurses" ,ncurses)))
182 (home-page "http://joe-editor.sourceforge.net/")
183 (synopsis "Console screen editor")
184 (description
7904f18a
EB
185 "JOE is a powerful console screen editor with a \"mode-less\" user
186interface similar to many user-friendly editors. JOE has some of the key
187bindings and many of the powerful features of GNU Emacs.")
f255a6db 188 (license license:gpl3+)))
0bf11648
FS
189
190(define-public leafpad
191 (package
192 (name "leafpad")
193 (version "0.8.18.1")
194 (source (origin
195 (method url-fetch)
b7fd77ef 196 (uri (string-append "mirror://savannah/"
0bf11648
FS
197 "leafpad/leafpad-" version ".tar.gz"))
198 (sha256
199 (base32
200 "0b0az2wvqgvam7w0ns1j8xp2llslm1rx6h7zcsy06a7j0yp257cm"))))
4f038621 201 (build-system glib-or-gtk-build-system)
0bf11648
FS
202 (native-inputs
203 `(("intltool" ,intltool)
204 ("pkg-config" ,pkg-config)))
205 (inputs
206 `(("gtk+" ,gtk+-2)))
dde5831c 207 (home-page "http://tarot.freeshell.org/leafpad/")
0bf11648
FS
208 (synopsis "GTK+ based text editor")
209 (description "Leafpad is a GTK+ text editor that emphasizes simplicity. As
210development focuses on keeping weight down to a minimum, only the most essential
211features are implemented in the editor. Leafpad is simple to use, is easily
212compiled, requires few libraries, and starts up quickly. ")
213 (license license:gpl2+)))
3312fda0 214
215(define-public e3
216 (package
217 (name "e3")
218 (version "2.82")
219 (source (origin
220 (method url-fetch)
221 (uri (string-append "https://sites.google.com/site/e3editor/Home/"
222 "e3-" version ".tgz"))
223 (sha256
224 (base32
225 "0919kadkas020maqq37852isnzp053q2fnws2zh3mz81d1jiviak"))
226 (modules '((guix build utils)))
227
228 ;; Remove pre-built binaries.
6cbee49d
MW
229 (snippet '(begin
230 (delete-file-recursively "bin")
231 #t))))
3312fda0 232 (build-system gnu-build-system)
233 (arguments
234 `(#:tests? #f
235 #:make-flags (list (string-append "PREFIX="
236 (assoc-ref %outputs "out")))
237 #:phases (modify-phases %standard-phases
238 (delete 'configure))))
239 (native-inputs
240 `(("nasm" ,nasm)))
241 (home-page "https://sites.google.com/site/e3editor/")
242 (synopsis "Tiny text editor written in assembly")
243 (description
244 "e3 is a micro text editor with an executable code size between 3800 and
24535000 bytes. Except for ``syntax highlighting'', the e3 binary supports all
246of the basic functions one expects plus built in arithmetic calculations.
247UTF-8 coding of unicode characters is supported as well. e3 can use
248Wordstar-, EMACS-, Pico, Nedit or vi-like key bindings. e3 can be used on
24916, 32, and 64-bit CPUs.")
250 (supported-systems '("x86_64-linux" "i686-linux"))
251 (license license:gpl2+)))
bcd757fd
LC
252
253(define-public mg
254 (package
255 (name "mg")
77100119 256 (version "20180927")
bcd757fd 257 (source (origin
a4d8b386
TGR
258 (method git-fetch)
259 (uri (git-reference
260 (url "https://github.com/hboetes/mg")
261 (commit version)))
262 (file-name (git-file-name name version))
bcd757fd
LC
263 (sha256
264 (base32
77100119 265 "14vrm8lvwksf697sqks7xfd1xaqjlqjc9afjk33sksq5p27wr203"))
bcd757fd 266 (modules '((guix build utils)))
6cbee49d
MW
267 (snippet '(begin
268 (substitute* "GNUmakefile"
269 (("/usr/bin/") ""))
270 #t))))
bcd757fd
LC
271 (build-system gnu-build-system)
272 (native-inputs
273 `(("pkg-config" ,pkg-config)))
274 (inputs
275 `(("libbsd" ,libbsd)
276 ("ncurses" ,ncurses)))
277 (arguments
278 ;; No test suite available.
279 '(#:tests? #f
280 #:make-flags (list (string-append "prefix=" %output)
bcd757fd
LC
281 "CC=gcc")
282 #:phases (modify-phases %standard-phases
a4d8b386 283 (delete 'configure) ; no configure script
217ce570 284 (add-before 'build 'correct-location-of-difftool
285 (lambda _
286 (substitute* "buffer.c"
287 (("/usr/bin/diff")
288 (which "diff")))
289 #t))
bcd757fd
LC
290 (add-before 'install 'patch-tutorial-location
291 (lambda* (#:key outputs #:allow-other-keys)
292 (substitute* "mg.1"
293 (("/usr") (assoc-ref outputs "out")))
294 #t))
295 (add-after 'install 'install-tutorial
296 (lambda* (#:key outputs #:allow-other-keys)
297 (let* ((out (assoc-ref outputs "out"))
298 (doc (string-append out "/share/doc/mg")))
299 (install-file "tutorial" doc)
300 #t))))))
c3d82885 301 (home-page "https://homepage.boetes.org/software/mg/")
bcd757fd
LC
302 (synopsis "Microscopic GNU Emacs clone")
303 (description
16fcca64
TGR
304 "Mg (@command{mg}) is a GNU Emacs style editor, with which it is
305\"broadly\" compatible. This is a portable version of the mg maintained by the
306OpenBSD team.")
bcd757fd 307 (license license:public-domain)))
04918a00 308
3fad9a69
NG
309(define-public qemacs
310 (package
311 (name "qemacs")
312 (version "0.3.3")
313 (source
314 (origin
315 (method url-fetch)
316 (uri (string-append "https://bellard.org/qemacs/"
317 "qemacs-" version ".tar.gz"))
318 (sha256
319 (base32 "156z4wpj49i6j388yjird5qvrph7hz0grb4r44l4jf3q8imadyrg"))))
320 (build-system gnu-build-system)
321 (arguments
322 `(#:tests? #f ;no test
323 #:phases
324 (modify-phases %standard-phases
325 (add-before 'build 'build-qhtml
326 ;; Build fails without first creating qHTML library.
327 (lambda _ (invoke "make" "-C" "libqhtml")))
328 (add-before 'install 'fix-man-pages-directory
329 ;; Install in $out/share/man instead of $out/man.
330 (lambda _
331 (substitute* "Makefile"
332 (("/man/man1" all) (string-append "/share" all)))
333 #t))
334 (add-before 'install 'create-directories
335 ;; Ensure directories exist before installing files.
336 (lambda* (#:key outputs #:allow-other-keys)
337 (let ((out (assoc-ref outputs "out")))
338 (for-each (lambda (d) (mkdir-p (string-append out d)))
339 '("/bin" "/share/man/man1" "/share/qe"))
340 #t)))
341 (add-after 'install 'install-extra-documentation
342 ;; Install sample configuration file, Info, and HTML manual.
343 (lambda* (#:key outputs #:allow-other-keys)
344 (let* ((share (string-append (assoc-ref outputs "out") "/share"))
345 (doc (string-append share "/doc/" ,name "-" ,version))
346 (html (string-append share "/html"))
347 (info (string-append share "/info"))
348 (makeinfo (string-append (assoc-ref %build-inputs "texinfo")
349 "/bin/makeinfo")))
350 ;; First fix Texinfo documentation, create appropriate
351 ;; directories, then generate Info and HTML files there.
352 (substitute* "qe-doc.texi"
353 (("^M-([{}])" _ bracket) (string-append "M-@" bracket)))
354 (for-each (lambda (d) (mkdir-p d)) (list html info))
355 (invoke makeinfo "qe-doc.texi" "-o" info)
356 (invoke makeinfo "qe-doc.texi" "--html" "--no-split" "-o" html)
357 ;; Install sample configuration file.
358 (install-file "config.eg" doc)
359 #t))))))
360 (native-inputs
361 `(("texinfo" ,texinfo)))
362 (inputs
363 `(("libx11" ,libx11)
364 ("libxext" ,libxext)
365 ("libxv" ,libxv)))
366 (home-page "https://bellard.org/qemacs/")
367 (synopsis "Small but powerful text editor")
368 (description "QEmacs (for Quick Emacs) is a very small but
369powerful editor. It has features that even big editors lack:
370
371@itemize
372
373@item Full screen editor with an Emacs look and feel with all Emacs
374common features: multi-buffer, multi-window, command mode, universal
375argument, keyboard macros, config file with C-like syntax, minibuffer
376with completion and history.
377
378@item Can edit files of hundreds of Megabytes without being slow by
379using a highly optimized internal representation and by mmaping the
380file.
381
382@item Full Unicode support, including multi charset handling (8859-x,
383UTF8, SJIS, EUC-JP, ...) and bidirectional editing respecting the
384Unicode bidi algorithm. Arabic and Indic scripts handling (in
385progress).
386
387@item WYSIWYG HTML/XML/CSS2 mode graphical editing. Also supports
388Lynx like rendering on VT100 terminals.
389
390@item WYSIWYG DocBook mode based on XML/CSS2 renderer.
391
392@item C mode: coloring with immediate update. Emacs like auto-indent.
393
394@item Shell mode: colorized VT100 emulation so that your shell work
395exactly as you expect. Compile mode with next/prev error.
396
397@item Input methods for most languages, including Chinese (input
398methods come from the Yudit editor).
399
400@item Hexadecimal editing mode with insertion and block commands.
401Unicode hexa editing is also supported.
402
403@item Works on any VT100 terminals without termcap. UTF8 VT100
404support included with double width glyphs.
405
406@item X11 support. Support multiple proportional fonts at the same
407time (as XEmacs). X Input methods supported. Xft extension supported
408for anti aliased font display.
409
410@item Small! Full version (including HTML/XML/CSS2/DocBook rendering
411and all charsets): 200KB big. Basic version (without bidir/unicode
412scripts/input/X11/C/Shell/HTML/Dired): 49KB.
413@end itemize")
414 (license license:lgpl2.1+)))
415
04918a00
EB
416(define-public ghostwriter
417 (package
418 (name "ghostwriter")
58ab7f29 419 (version "1.7.4")
04918a00
EB
420 (source (origin
421 (method git-fetch)
422 (uri (git-reference
423 (url "https://github.com/wereturtle/ghostwriter.git")
424 (commit (string-append "v" version))))
425 (file-name (git-file-name name version))
426 (sha256
427 (base32
58ab7f29 428 "1pqlr08z5syqcq5p282asxwzrrm7c1w94baxyb467swh8yp3fj5m"))))
04918a00
EB
429 (build-system gnu-build-system)
430 (native-inputs
431 `(("pkg-config" ,pkg-config)
58ab7f29 432 ("qttools" ,qttools))) ; for lrelease
04918a00
EB
433 (inputs
434 `(("hunspell" ,hunspell)
435 ("qtbase" ,qtbase)
436 ("qtmultimedia" ,qtmultimedia)
437 ("qtsvg" ,qtsvg)
438 ("qtwebkit" ,qtwebkit)))
439 (arguments
440 `(#:phases
441 (modify-phases %standard-phases
442 (replace 'configure
443 (lambda* (#:key outputs #:allow-other-keys)
444 (let ((out (assoc-ref outputs "out")))
445 (invoke "qmake" (string-append "PREFIX=" out)))))
446 (add-after 'configure 'create-translations
447 (lambda _
448 ;; `lrelease` will not overwrite, so delete existing .qm files
449 (for-each delete-file (find-files "translations" ".*\\.qm"))
450 (apply invoke "lrelease" (find-files "translations" ".*\\.ts"))))
451 ;; Ensure that icons are found at runtime.
452 (add-after 'install 'wrap-executable
453 (lambda* (#:key inputs outputs #:allow-other-keys)
454 (let ((out (assoc-ref outputs "out")))
455 (wrap-program (string-append out "/bin/ghostwriter")
456 `("QT_PLUGIN_PATH" ":" prefix
457 ,(map (lambda (label)
458 (string-append (assoc-ref inputs label)
459 "/lib/qt5/plugins/"))
460 '("qtsvg" "qtmultimedia"))))))))))
461 (home-page "https://wereturtle.github.io/ghostwriter/")
462 (synopsis "Write without distractions")
463 (description
464 "@code{ghostwriter} provides a relaxing, distraction-free writing
465environment with Markdown markup.")
58ab7f29 466 (license license:gpl3+))) ; icons/* under CC-BY-SA3
2238211a 467
1fffba66
NG
468(define-public manuskript
469 (package
470 (name "manuskript")
d5a08205 471 (version "0.11.0")
1fffba66
NG
472 (source
473 (origin
474 (method git-fetch)
475 (uri (git-reference
476 (url "https://github.com/olivierkes/manuskript.git")
477 (commit version)))
478 (file-name (git-file-name name version))
479 (sha256
d5a08205 480 (base32 "1l6l9k6k69yv8xqpll0zv9cwdqqg4zvxy90l6sx5nv2yywh5crla"))))
1fffba66
NG
481 (build-system python-build-system)
482 (arguments
483 `(#:tests? #f ;no test
484 #:phases
485 (modify-phases %standard-phases
486 (delete 'configure)
487 (delete 'build)
488 (replace 'install
489 (lambda* (#:key outputs #:allow-other-keys)
490 (let* ((out (assoc-ref outputs "out"))
491 (share (string-append out "/share/manuskript")))
492 ;; Install data.
493 (mkdir-p share)
494 (for-each
495 (lambda (d)
496 (let ((destination (string-append share "/" d)))
497 (mkdir-p destination)
498 (copy-recursively d destination)))
499 '("bin" "i18n" "icons" "libs" "manuskript" "resources"))
500 ;; Install documentation.
501 (let ((doc (string-append out
502 "/doc/manuskript-" ,version
503 "/sample-projects")))
504 (mkdir-p doc)
505 (copy-recursively "sample-projects" doc))
506 ;; Wrap executable in "$out/share/manuskript/bin" and
507 ;; link to it from "$out/bin".
508 (let ((bin (string-append out "/bin"))
509 (executable (string-append share "/bin/manuskript")))
510 (wrap-program executable
511 (list "PYTHONPATH" 'prefix (list (getenv "PYTHONPATH"))))
512 (mkdir-p bin)
513 (with-directory-excursion bin
514 (symlink (string-append share "/bin/manuskript")
515 "manuskript")))
516 ;; Install icons and create .desktop file.
517 (let ((apps (string-append out "/share/applications"))
518 (icons-dir (string-append out "/share/pixmaps")))
519 (install-file "icons/Manuskript/manuskript.svg" icons-dir)
520 (mkdir-p apps)
521 (with-output-to-file (string-append apps "/manuskript.desktop")
522 (lambda _
523 (format #t
524 "[Desktop Entry]~@
525 Name=Manuskript~@
526 MimeType=application/x-manuskript-book;~@
527 Exec=~a/bin/manuskript %f~@
528 Comment=Tool for writers~@
529 Comment[es]=Herramienta para escritores/as~@
530 Keywords=manuskript;office;write;edit;novel;text;msk~@
531 Terminal=false~@
532 Type=Application~@
533 Icon=manuskript~@
534 Categories=Office;WordProcessor;~%"
535 out))))
536 #t))))))
537 (inputs
538 `(("ghc-pandoc" ,ghc-pandoc)
539 ("python-lxml" ,python-lxml)
540 ("python-markdown" ,python-markdown)
541 ("python-pyqt" ,python-pyqt)
542 ("qtsvg" ,qtsvg)))
543 (home-page "http://www.theologeek.ch/manuskript/")
544 (synopsis "Tool for writers")
545 (description "Manuskript provides a rich environment to help
546writers create their first draft and then further refine and edit
547their masterpiece. With Manuskript you can:
548
549@itemize
550@item Grow your premise from one sentence, to a paragraph, to a full
551summary,
552@item Create characters,
553@item Conceive plots,
554@item Construct outlines (Outline mode and/or Index cards),
555@item Write with focus (Distraction free mode),
556@item Build worlds,
557@item Track items,
558@item Edit and re-organize chapters and scenes,
559@item View Story line,
560@item Compose with fiction or non-fiction templates and writing modes,
561@item Import and export document formats such as HTML, ePub,
562OpenDocument, DocX, and more.
563@end itemize
564
565Additionally Manuskript can help in many more ways with a spell
566checker, markdown highlighter, frequency analyzer, and automatic save
567in plain text file format.")
568 (license license:gpl3+)))
569
2238211a
EF
570(define-public editorconfig-core-c
571 (package
572 (name "editorconfig-core-c")
573 (version "0.12.3")
574 (source
575 (origin
576 (method git-fetch)
577 (uri (git-reference
578 (url "https://github.com/editorconfig/editorconfig-core-c.git")
579 (commit (string-append "v" version))))
580 (file-name (git-file-name name version))
581 (sha256
582 (base32
583 "0jkc69r4jwn4rih6h6cqvgljjc3ff49cxj8286mi515aczr48cm1"))))
584 (build-system cmake-build-system)
585 (arguments
586 '(#:phases
587 (modify-phases %standard-phases
588 (add-after 'unpack 'insert-tests
589 (lambda* (#:key inputs #:allow-other-keys)
590 (let ((tests (assoc-ref inputs "tests")))
591 (copy-recursively tests "tests"))
592 #t)))))
593 (native-inputs
594 `(("tests" ,(origin
595 (method git-fetch)
596 (uri (git-reference
597 (url "https://github.com/editorconfig/editorconfig-core-test")
598 (commit "6ea1d8ece62cac9cf72c79dce4879b046abe1fe7"))) ; matches version
599 (file-name (git-file-name "editorconfig-core-test" version))
600 (sha256
601 (base32
602 "1sf6910idnd4bgzbj8w8f9ldsbkaqa0lh6syymwy3hfqda63acj7"))))))
603 (inputs
604 `(("pcre2" ,pcre2)))
605 (home-page "https://editorconfig.org/")
606 (synopsis "EditorConfig core library written in C")
607 (description "EditorConfig makes it easy to maintain the correct coding
608style when switching between different text editors and between different
609projects. The EditorConfig project maintains a file format and plugins for
610various text editors which allow this file format to be read and used by those
611editors.")
612 (license license:bsd-2)))
75a137da
AE
613
614(define-public texmacs
615 (package
616 (name "texmacs")
ad9fd1ba 617 (version "1.99.11")
75a137da
AE
618 (source
619 (origin
620 (method url-fetch)
621 (uri (string-append "https://www.texmacs.org/Download/ftp/tmftp/"
622 "source/TeXmacs-" version "-src.tar.gz"))
623 (sha256
ad9fd1ba 624 (base32 "12bp0f34izzqimz49lfpgf4lyz3h45s9xbmk8v6zsawdjki76alg"))
75a137da
AE
625 (modules '((guix build utils)))
626 (snippet
627 '(begin
628 (delete-file-recursively "3rdparty")
629 #t))))
630 (build-system gnu-build-system)
631 (native-inputs
632 `(("pkg-config" ,pkg-config)))
633 (inputs
634 `(("freetype" ,freetype)
635 ("guile" ,guile-1.8)
636 ("perl" ,perl)
637 ("python" ,python-wrapper)
638 ("qt" ,qt-4)))
639 (arguments
ad9fd1ba 640 `(#:tests? #f ; no check target
75a137da
AE
641 #:phases
642 (modify-phases %standard-phases
643 (add-before 'configure 'gzip-flags
644 (lambda _
645 (substitute* "Makefile.in"
646 (("^GZIP = gzip -f") "GZIP = gzip -f -n")))))))
647 (synopsis "Editing platform with special features for scientists")
648 (description
649 "GNU TeXmacs is a text editing platform which is specialized for
650scientists. It is ideal for editing structured documents with different
651types of content. It has robust support for mathematical formulas and plots.
652 It can also act as an interface to external mathematical programs such as R
653and Octave. TeXmacs is completely extensible via Guile.")
654 (license license:gpl3+)
655 (home-page "https://www.texmacs.org/tmweb/home/welcome.en.html")))
c55cd98c
NG
656
657(define-public scintilla
658 (package
659 (name "scintilla")
3e6cb583
NG
660 (version "4.3.0")
661 (source
662 (origin
663 (method url-fetch)
664 (uri (let ((v (apply string-append (string-split version #\.))))
665 (string-append "https://www.scintilla.org/scintilla" v ".tgz")))
666 (sha256
667 (base32 "0c52b2wg0y55kv3w7rnzp0nbd1yn2kksy0w8bjdp3gkl0v28wwx5"))))
c55cd98c
NG
668 (build-system gnu-build-system)
669 (arguments
670 `(#:make-flags (list "GTK3=1" "CC=gcc" "-Cgtk")
671 #:tests? #f ;require un-packaged Pyside
672 #:phases
673 (modify-phases %standard-phases
674 (delete 'configure) ;no configure script
675 (add-after 'unpack 'build-shared-library
676 (lambda _
677 (substitute* "gtk/makefile"
678 (("scintilla\\.a") "libscintilla.so")
679 (("\\$\\(AR\\) \\$\\(ARFLAGS\\) \\$@ \\$\\^")
680 "$(CC) -shared $^ -o $@")
681 (("\\$\\(RANLIB\\) \\$@") ""))
682 #t))
c55cd98c
NG
683 (replace 'install
684 (lambda* (#:key outputs #:allow-other-keys)
685 (let* ((out (assoc-ref outputs "out"))
686 (lib (string-append out "/lib"))
687 (include (string-append out "/include")))
688 (install-file "bin/libscintilla.so" lib)
689 (for-each (lambda (f) (install-file f include))
690 (find-files "include/" "."))
691 #t))))))
692 (native-inputs
dee632a8
NG
693 `(("pkg-config" ,pkg-config)
694 ("python" ,python-wrapper)))
c55cd98c
NG
695 (inputs
696 `(("gtk+" ,gtk+)))
697 (home-page "https://www.scintilla.org/")
698 (synopsis "Code editor for GTK+")
699 (description "Scintilla is a source code editing component for
700GTK+. It has the usual features found in text editing components, as
701well as some that are especially useful for editing and debugging
702source code; these include support for syntax styling, error
703indicators, code completion and call tips. Styling choices are more
704open than with many editors: Scintilla lets you use proportional
705fonts, bold and italics, multiple foreground and background colours,
706and multiple fonts.")
707 (license license:hpnd)))
2363ed01
NG
708
709(define-public geany
710 (package
711 (name "geany")
40e513fe 712 (version "1.36")
2363ed01
NG
713 (source (origin
714 (method url-fetch)
715 (uri (string-append "https://download.geany.org/"
716 "geany-" version ".tar.bz2"))
717 (sha256
718 (base32
40e513fe 719 "0gnm17cr4rf3pmkf0axz4a0fxwnvp55ji0q0lzy88yqbshyxv14i"))
2363ed01
NG
720 (modules '((guix build utils)))
721 (snippet '(begin
722 (delete-file-recursively "scintilla")
723 #t))))
724 (build-system gnu-build-system)
725 (native-inputs
726 `(("autoconf" ,autoconf)
727 ("automake" ,automake)
728 ("doxygen" ,doxygen)
729 ("glib" ,glib "bin")
730 ("intltool" ,intltool)
731 ("libtool" ,libtool)
732 ("pkg-config" ,pkg-config)
733 ("python-docutils" ,python-docutils))) ;for rst2html
734 (inputs
735 `(("gtk+" ,gtk+)
736 ("scintilla" ,scintilla)))
737 (arguments
738 `(#:phases
739 (modify-phases %standard-phases
740 (add-after 'unpack 'use-scintilla-shared-library
741 (lambda* (#:key inputs #:allow-other-keys)
742 (substitute* "configure.ac"
743 (("scintilla/Makefile") "")
744 (("scintilla/include/Makefile") ""))
745 (substitute* "Makefile.am"
746 (("scintilla ") ""))
747 (substitute* "src/Makefile.am"
748 (("\\$\\(top_builddir\\)/scintilla/libscintilla.la") "")
749 (("geany_LDFLAGS =" all) (string-append all " -lscintilla")))
750 (substitute* "doc/Makefile.am"
751 (("\\$\\(INSTALL_DATA\\) \\$\\(top_srcdir\\)/scintilla/License.txt \\$\\(DOCDIR\\)/ScintillaLicense.txt") ""))
40e513fe
NG
752 (substitute* "tests/Makefile.am"
753 (("AM_LDFLAGS =" all) (string-append all " -lscintilla")))
2363ed01
NG
754 (for-each delete-file (list "autogen.sh" "configure" "Makefile.in"))
755 #t)))))
756 (home-page "https://www.geany.org")
757 (synopsis "Fast and lightweight IDE")
758 (description "Geany is a small and fast Integrated Development
759Environment (IDE) that only has a few dependencies on other packages and is as
760independent as possible from special desktop environments like KDE or GNOME.
761
762The basic features of Geany are:
763@itemize
764@item syntax highlighting
765@item code completion
766@item auto completion of often constructed constructs like if, for and while
767@item auto completion of XML and HTML tags
768@item call tips
769@item folding
770@item many supported filetypes like C, Java, PHP, HTML, Python, Perl, Pascal
771@item symbol lists
772@item embedded terminal emulation
773@item extensibility through plugins
774@end itemize")
775 (license license:gpl2+)))
2207d522
NG
776
777(define-public fe
778 (package
779 (name "fe")
780 ;; Stable release is 1.8. However, this development version
781 ;; introduces support for UTF-8.
782 (version "2.0")
783 (source (origin
784 (method url-fetch)
785 (uri (string-append "http://www.moria.de/~michael/fe/"
786 "fe-" version ".tar.gz"))
787 (sha256
788 (base32
789 "1hwws7si1752z6hp61zxznvgsb6846lp8zl1hn5ddhsbafwalwb9"))))
790 (build-system gnu-build-system)
791 (arguments
792 `(#:tests? #f ;no test
793 ;; Sendmail is only used to send a crash log. Disable the
794 ;; feature since it is (1) undocumented (2) not very useful.
795 #:configure-flags (list "--disable-sendmail")
796 #:phases
797 (modify-phases %standard-phases
798 (add-after 'install 'install-doc
799 (lambda* (#:key outputs #:allow-other-keys)
800 (let* ((out (assoc-ref outputs "out"))
801 (doc (string-append out "/share/doc/" ,name "-" ,version)))
802 (for-each (lambda (f) (install-file f doc))
803 '("fe.doc" "fe.html" "fe.ps" "feref.ps" "README"))
804 #t))))))
805 (native-inputs
806 `(("gettext" ,gettext-minimal)))
807 (inputs
808 `(("ncurses" ,ncurses)))
809 (home-page "http://www.moria.de/~michael/fe/")
810 (synopsis "Small folding editor")
811 (description "Fe is a small folding editor. It allows to fold
812arbitrary text regions; it is not bound to syntactic units.
813
814Fe has no configuration or extension language and requires no setup.
99ce2055 815Its user interface is emacs-like and it has menus for the very most
2207d522
NG
816important functions to help beginners. Further there is a reference
817card. It offers:
818
819@itemize
820@item Regions and Emacs-like kill ring
821@item Incremental search
822@item Keyboard macros
823@item Editing binary files
824@item Multiple windows and views
825@item Compose function for Latin 1 characters
826@end itemize")
827 (license license:gpl2+)))
a78364e9
DM
828
829(define-public ne
830 (package
831 (name "ne")
832 (version "3.2.1")
833 (source (origin
834 (method git-fetch)
835 (uri (git-reference
836 (url "https://github.com/vigna/ne.git")
837 (commit version)))
838 (file-name (git-file-name name version))
839 (sha256
840 (base32
841 "0h6d08cnwrk96ss83i9bragwwanph6x54sm3ak1z81146dsqsiif"))))
842 (build-system gnu-build-system)
843 (native-inputs
844 `(("perl" ,perl)
845 ("texinfo" ,texinfo)))
846 (inputs
847 `(("ncurses" ,ncurses)))
848 (arguments
849 `(#:tests? #f
850 #:make-flags
851 (list "CC=gcc"
852 (string-append "PREFIX=" (assoc-ref %outputs "out"))
853 (string-append "LDFLAGS=-L" (assoc-ref %build-inputs "ncurses")
854 "/lib"))
855 #:phases
856 (modify-phases %standard-phases
857 (replace 'configure
858 (lambda _
859 (substitute* "src/makefile"
860 (("-lcurses") "-lncurses"))
861 #t)))))
862 (home-page "http://ne.di.unimi.it/")
863 (synopsis "Text editor with menu bar")
864 (description "This package provides a modeless text editor with menu bar.
865It supports syntax highlighting, regular expressions, configurable menus,
866keybindings, autocomplete and unlimited undo. It can pipe a marked block
867of text through any command line filter. It can also open very large binary
868files. It was originally developed on the Amiga 3000T.")
869 (license license:gpl3+)))