gnu: emacs-helm: Update to 3.8.7.
[jackhill/guix/guix.git] / gnu / packages / syndication.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2016, 2017, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il>
3 ;;; Copyright © 2018, 2019, 2021 Tobias Geerinckx-Rice <me@tobias.gr>
4 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
5 ;;; Copyright © 2021 Felix Gruber <felgru@posteo.net>
6 ;;; Copyright © 2022 Luis Felipe López Acevedo <luis.felipe.la@protonmail.com>
7 ;;;
8 ;;; This file is part of GNU Guix.
9 ;;;
10 ;;; GNU Guix is free software; you can redistribute it and/or modify it
11 ;;; under the terms of the GNU General Public License as published by
12 ;;; the Free Software Foundation; either version 3 of the License, or (at
13 ;;; your option) any later version.
14 ;;;
15 ;;; GNU Guix is distributed in the hope that it will be useful, but
16 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;;; GNU General Public License for more details.
19 ;;;
20 ;;; You should have received a copy of the GNU General Public License
21 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
22
23 (define-module (gnu packages syndication)
24 #:use-module ((guix licenses) #:prefix license:)
25 #:use-module (guix download)
26 #:use-module (guix git-download)
27 #:use-module (guix packages)
28 #:use-module (guix utils)
29 #:use-module (guix build-system cargo)
30 #:use-module (guix build-system glib-or-gtk)
31 #:use-module (guix build-system gnu)
32 #:use-module (guix build-system meson)
33 #:use-module (guix build-system python)
34 #:use-module (guix build-system qt)
35 #:use-module (gnu packages)
36 #:use-module (gnu packages autotools)
37 #:use-module (gnu packages base)
38 #:use-module (gnu packages check)
39 #:use-module (gnu packages crates-io)
40 #:use-module (gnu packages curl)
41 #:use-module (gnu packages documentation)
42 #:use-module (gnu packages freedesktop)
43 #:use-module (gnu packages gettext)
44 #:use-module (gnu packages glib)
45 #:use-module (gnu packages gnome)
46 #:use-module (gnu packages gstreamer)
47 #:use-module (gnu packages gtk)
48 #:use-module (gnu packages kde-frameworks)
49 #:use-module (gnu packages ncurses)
50 #:use-module (gnu packages pkg-config)
51 #:use-module (gnu packages python)
52 #:use-module (gnu packages python-check)
53 #:use-module (gnu packages python-xyz)
54 #:use-module (gnu packages python-web)
55 #:use-module (gnu packages qt)
56 #:use-module (gnu packages ruby)
57 #:use-module (gnu packages rust)
58 #:use-module (gnu packages sqlite)
59 #:use-module (gnu packages time)
60 #:use-module (gnu packages tls)
61 #:use-module (gnu packages video)
62 #:use-module (gnu packages web)
63 #:use-module (gnu packages webkit)
64 #:use-module (gnu packages xml)
65 #:use-module (gnu packages xorg)
66 #:use-module (srfi srfi-1))
67
68 (define-public cawbird
69 (package
70 (name "cawbird")
71 (version "1.4.2")
72 (source
73 (origin
74 (method git-fetch)
75 (uri (git-reference
76 (url "https://github.com/IBBoard/cawbird")
77 (commit (string-append "v"version))))
78 (file-name (git-file-name name version))
79 (sha256
80 (base32 "17575cp5qcgsqf37y3xqg3vr6l2j8bbbkmy2c1l185rxghfacida"))))
81 (build-system meson-build-system)
82 (arguments
83 `(#:glib-or-gtk? #t
84 #:configure-flags
85 ;; Cawbirds's default key and secret for OAuth process with twitter.
86 (list
87 "-Dconsumer_key_base64=VmY5dG9yRFcyWk93MzJEZmhVdEk5Y3NMOA=="
88 "-Dconsumer_secret_base64=MThCRXIxbWRESDQ2Y0podzVtVU13SGUyVGlCRXhPb3BFRHhGYlB6ZkpybG5GdXZaSjI=")
89 #:phases
90 (modify-phases %standard-phases
91 (add-after 'unpack 'disable-failing-tests
92 (lambda _
93 ;; These tests require networking.
94 (substitute* "tests/meson.build"
95 (("[ \t]*.*avatardownload.*$") "")
96 (("[ \t]*.*filters.*$") "")
97 (("[ \t]*.*friends.*$") "")
98 (("[ \t]*.*inlinemediadownloader.*$") "")
99 (("[ \t]*.*tweetparsing.*$") "")
100 (("[ \t]*.*usercounter.*$") ""))))
101 (delete 'check)
102 (add-after 'install 'custom-check
103 (lambda* (#:key outputs tests? #:allow-other-keys)
104 (when tests?
105 ;; Tests require a running X server.
106 (system "Xvfb :1 +extension GLX &")
107 (setenv "DISPLAY" ":1")
108 ;; Tests write to $HOME.
109 (setenv "HOME" (getcwd))
110 ;; Tests look for gsettings-schemas installed by the package.
111 (setenv "XDG_DATA_DIRS"
112 (string-append (getenv "XDG_DATA_DIRS")
113 ":" (assoc-ref outputs "out") "/share"))
114 (invoke "meson" "test"))))
115 (add-after 'glib-or-gtk-wrap 'wrap-paths
116 (lambda* (#:key outputs #:allow-other-keys)
117 (let* ((out (assoc-ref outputs "out"))
118 (bin (string-append out "/bin/"))
119 (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH"))
120 (gi-typelib-path (getenv "GI_TYPELIB_PATH")))
121 (wrap-program (string-append bin "cawbird")
122 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix (,gst-plugin-path))
123 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path)))))))))
124 (native-inputs
125 `(("gettext" ,gettext-minimal)
126 ("glib:bin" ,glib "bin")
127 ("gobject-introspection" ,gobject-introspection)
128 ("gtk+:bin" ,gtk+ "bin")
129 ("pkg-config" ,pkg-config)
130 ("vala" ,vala)
131 ("xmllint" ,libxml2)
132 ("xorg-server" ,xorg-server-for-tests)))
133 (inputs
134 `(("glib" ,glib)
135 ("gsettings-desktop-schemas" ,gsettings-desktop-schemas)
136 ("gspell" ,gspell)
137 ("gstreamer" ,gstreamer)
138 ("gst-libav" ,gst-libav)
139 ("gst-plugins-bad" ,gst-plugins-bad)
140 ("gst-plugins-base" ,gst-plugins-base)
141 ("gst-plugins-good" ,gst-plugins-good)
142 ("gtk+" ,gtk+)
143 ("json-glib" ,json-glib)
144 ("liboauth" ,liboauth)
145 ("libsoup" ,libsoup)
146 ("rest" ,rest)
147 ("sqlite" ,sqlite)
148 ("x11" ,libx11)))
149 (propagated-inputs
150 (list dconf))
151 (synopsis "Client for Twitter")
152 (description "Cawbird is a Twitter client built with GTK and Vala.
153 It supports all features except non-mention notifications, polls, threads and
154 cards.")
155 (home-page "https://ibboard.co.uk/cawbird/")
156 (license license:gpl3+)))
157
158 (define-public giara
159 (package
160 (name "giara")
161 (version "0.3")
162 (source
163 (origin
164 (method git-fetch)
165 (uri (git-reference
166 (url "https://gitlab.gnome.org/World/giara")
167 (commit version)))
168 (file-name (git-file-name name version))
169 ;; To fix authentication while adding accounts.
170 (patches (search-patches "giara-fix-login.patch"))
171 (sha256
172 (base32 "004qmkfrgd37axv0b6hfh6v7nx4pvy987k5yv4bmlmkj9sbqm6f9"))))
173 (build-system meson-build-system)
174 (arguments
175 `(#:glib-or-gtk? #t
176 #:phases
177 (modify-phases %standard-phases
178 (add-after 'glib-or-gtk-wrap 'wrap-paths
179 (lambda* (#:key outputs #:allow-other-keys)
180 (let* ((out (assoc-ref outputs "out"))
181 (bin (string-append out "/bin/"))
182 (lib (string-append out "/lib/python"
183 ,(version-major+minor
184 (package-version python))
185 "/site-packages")))
186 (wrap-program (string-append bin "giara")
187 `("GUIX_PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH") ,lib))
188 `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH"))))))))))
189 (native-inputs
190 `(("gettext" ,gettext-minimal)
191 ("glib:bin" ,glib "bin")
192 ("gobject-introspection" ,gobject-introspection)
193 ("gtk+:bin" ,gtk+ "bin")
194 ("pkg-config" ,pkg-config)
195 ("xmllint" ,libxml2)))
196 (inputs
197 `(("glib" ,glib)
198 ("gtk+" ,gtk+)
199 ("gtksourceview" ,gtksourceview)
200 ("libhandy" ,libhandy)
201 ("python" ,python)
202 ("python-beautifulsoup" ,python-beautifulsoup4)
203 ("python-dateutil" ,python-dateutil)
204 ("python-mistune" ,python-mistune)
205 ("python-pillow" ,python-pillow)
206 ("python-praw" ,python-praw)
207 ("python-pycairo" ,python-pycairo)
208 ("python-pygobject" ,python-pygobject)
209 ("python-requests" ,python-requests)
210 ("webkitgtk" ,webkitgtk-with-libsoup2)))
211 (propagated-inputs
212 (list dconf))
213 (synopsis "Client for Reddit")
214 (description "Giara is a reddit app, built with Python, GTK and Handy.")
215 (home-page "https://giara.gabmus.org/")
216 (license license:gpl3+)))
217
218 (define-public newsboat
219 (package
220 (name "newsboat")
221 (version "2.26")
222 (source
223 (origin
224 (method url-fetch)
225 (uri (string-append "https://newsboat.org/releases/" version
226 "/newsboat-" version ".tar.xz"))
227 (sha256
228 (base32 "061w86jffyi49m4d9n974a3pd1svbw3azmh0qx8h2v7h0178791l"))))
229 (build-system cargo-build-system)
230 (native-inputs
231 `(("gettext" ,gettext-minimal)
232 ("openssl" ,openssl)
233 ("pkg-config" ,pkg-config)
234 ;; For building documentation.
235 ("asciidoctor" ,ruby-asciidoctor)))
236 (inputs
237 (list curl
238 json-c
239 libxml2
240 ncurses
241 stfl
242 sqlite))
243 (arguments
244 `(#:modules ((guix build cargo-build-system)
245 (guix build utils)
246 ((guix build gnu-build-system) #:prefix gnu:))
247 #:vendor-dir "vendor"
248 #:install-source? #f
249 #:cargo-inputs
250 (("rust-backtrace" ,rust-backtrace-0.3)
251 ("rust-bitflags" ,rust-bitflags-1)
252 ("rust-chrono" ,rust-chrono-0.4)
253 ("rust-curl-sys" ,rust-curl-sys-0.4)
254 ("rust-cxx" ,rust-cxx-1)
255 ("rust-fastrand" ,rust-fastrand-1)
256 ("rust-gettext-rs" ,rust-gettext-rs-0.7)
257 ("rust-lexopt" ,rust-lexopt-0.2)
258 ("rust-libc" ,rust-libc-0.2)
259 ("rust-md5" ,rust-md5-0.7)
260 ("rust-natord" ,rust-natord-1)
261 ("rust-nom" ,rust-nom-7)
262 ("rust-once-cell" ,rust-once-cell-1)
263 ("rust-percent-encoding" ,rust-percent-encoding-2)
264 ("rust-url" ,rust-url-2)
265 ("rust-unicode-width" ,rust-unicode-width-0.1)
266 ("rust-xdg" ,rust-xdg-2))
267 #:cargo-development-inputs
268 (("rust-cxx-build" ,rust-cxx-build-1)
269 ("rust-tempfile" ,rust-tempfile-3)
270 ("rust-proptest" ,rust-proptest-1)
271 ("rust-section-testing" ,rust-section-testing-0.0))
272 #:phases
273 (modify-phases %standard-phases
274 (add-after 'configure 'dont-vendor-self
275 (lambda* (#:key vendor-dir #:allow-other-keys)
276 ;; Don't keep the whole tarball in the vendor directory
277 (delete-file-recursively
278 (string-append vendor-dir "/" ,name "-" ,version ".tar.xz"))))
279 (add-after 'unpack 'patch-source
280 (lambda* (#:key outputs #:allow-other-keys)
281 (substitute* "Makefile"
282 (("Cargo.lock") "")
283 ;; Replace the prefix in the Makefile.
284 (("/usr/local") (assoc-ref outputs "out")))))
285 (replace 'build
286 (assoc-ref gnu:%standard-phases 'build))
287 (replace 'check
288 (lambda args
289 ((assoc-ref gnu:%standard-phases 'check)
290 #:test-target "test")))
291 (replace 'install
292 (assoc-ref gnu:%standard-phases 'install)))))
293 (native-search-paths
294 ;; Newsboat respects CURL_CA_BUNDLE.
295 (list (search-path-specification
296 (variable "CURL_CA_BUNDLE")
297 (file-type 'regular)
298 (separator #f) ;single entry
299 (files '("etc/ssl/certs/ca-certificates.crt")))))
300 (home-page "https://newsboat.org/")
301 (synopsis "Text-mode RSS and Atom feed reader with podcast support")
302 (description "Newsboat is a feed reader for @dfn{RSS} and @dfn{Atom}, XML
303 formats widely used to transmit, publish, and syndicate news or blog articles.
304 It's designed for use on text terminals, and to have a coherent and easy-to-use
305 interface that might look familiar to @command{mutt} or @command{slrn} users.
306
307 Newsboat supports OPML import/exports, HTML rendering, podcasts (with
308 @command{podboat}), off-line reading, searching and storing articles to your
309 file system, and many more features.")
310 (properties '((release-monitoring-url . "https://newsboat.org/news.atom")))
311 (license (list license:gpl2+ ; filter/*
312 license:expat)))) ; everything else
313
314 (define-public newsboat-2.13
315 (package
316 (inherit newsboat)
317 (version "2.13")
318 (source
319 (origin
320 (method url-fetch)
321 (uri (string-append "https://newsboat.org/releases/" version
322 "/newsboat-" version ".tar.xz"))
323 (sha256
324 (base32
325 "0pik1d98ydzqi6055vdbkjg5krwifbk2hy2f5jp5p1wcy2s16dn7"))))
326 (build-system gnu-build-system)
327 (native-inputs
328 `(,@(fold alist-delete (package-native-inputs newsboat)
329 '("asciidoctor" "openssl"))
330 ;; For building documentation.
331 ("asciidoc" ,asciidoc)))
332 (inputs
333 (modify-inputs (package-inputs newsboat)
334 (replace "json-c" json-c-0.13)))
335 (arguments
336 '(#:phases
337 (modify-phases %standard-phases
338 (delete 'configure) ; no configure script
339 (add-after 'build 'build-documentation
340 (lambda _
341 (invoke "make" "doc"))))
342 #:make-flags
343 (list (string-append "prefix=" (assoc-ref %outputs "out")))
344 #:test-target "test"))))
345
346 (define-public liferea
347 (package
348 (name "liferea")
349 (version "1.13.4")
350 (source
351 (origin
352 (method git-fetch)
353 (uri (git-reference
354 (url "https://github.com/lwindolf/liferea/")
355 (commit (string-append "v" version))))
356 (file-name (git-file-name name version))
357 (sha256
358 (base32 "1g9463bvswsm899j6dfhslcg6np70m5wq143mjicr24zy8d17bm7"))))
359 (build-system glib-or-gtk-build-system)
360 (arguments
361 `(#:configure-flags
362 (list
363 "--disable-static")
364 #:phases
365 (modify-phases %standard-phases
366 (add-before 'configure 'prepare-build-environment
367 (lambda* (#:key inputs #:allow-other-keys)
368 ;; Workaround for https://github.com/lwindolf/liferea/issues/767.
369 (setenv "WEBKIT_DISABLE_COMPOSITING_MODE" "1")))
370 (add-after 'install 'wrap-gi-python
371 (lambda* (#:key inputs outputs #:allow-other-keys)
372 (let ((out (assoc-ref outputs "out"))
373 (gi-typelib-path (getenv "GI_TYPELIB_PATH"))
374 (python-path (getenv "GUIX_PYTHONPATH")))
375 (wrap-program (string-append out "/bin/liferea")
376 `("GI_TYPELIB_PATH" ":" prefix (,gi-typelib-path))
377 `("GUIX_PYTHONPATH" ":" prefix (,python-path))))
378 #t)))))
379 (native-inputs
380 (list autoconf
381 automake
382 gettext-minimal
383 `(,glib "bin")
384 gobject-introspection
385 intltool
386 libtool
387 pkg-config
388 which))
389 (inputs
390 (list glib
391 glib-networking
392 gnome-keyring
393 gsettings-desktop-schemas
394 gstreamer
395 json-glib
396 libnotify
397 libpeas
398 libsecret
399 libsoup-minimal-2
400 libxml2
401 libxslt
402 pango
403 python
404 python-pycairo
405 python-pygobject
406 sqlite
407 webkitgtk-with-libsoup2))
408 (home-page "https://lzone.de/liferea/")
409 (synopsis "News reader for GTK/GNOME")
410 (description "Liferea is a desktop feed reader/news aggregator that
411 brings together all of the content from your favorite subscriptions into
412 a simple interface that makes it easy to organize and browse feeds.")
413 (license license:gpl2+)))
414
415 (define-public rtv
416 (package
417 (name "rtv")
418 (version "1.27.0")
419 (source
420 (origin
421 (method url-fetch)
422 (uri (pypi-uri "rtv" version))
423 (sha256
424 (base32 "0hvw426y09l3yzwv2zkb9hifpfbg9wd1gg0y3z3pxcli6n3ii2wl"))))
425 (build-system python-build-system)
426 (arguments
427 '(#:phases
428 (modify-phases %standard-phases
429 (add-before 'check 'set-environment-variables
430 (lambda* (#:key inputs #:allow-other-keys)
431 (setenv "HOME" (getcwd))
432 (setenv "TERM" "linux")
433 (setenv "TERMINFO"
434 (search-input-directory inputs "share/terminfo"))))
435 ;; Loading this as a library requires a controlling terminal, etc.
436 (delete 'sanity-check))
437 #:tests? #f)) ; tests fail: _curses.error: nocbreak() returned ERR
438 (propagated-inputs
439 (list python-beautifulsoup4 python-decorator python-kitchen
440 python-requests python-six))
441 (native-inputs
442 (list ncurses
443 python-coveralls
444 python-coverage
445 python-mock
446 python-pylint
447 python-pytest
448 python-vcrpy))
449 (home-page "https://github.com/michael-lazar/rtv")
450 (synopsis "Terminal viewer for Reddit (Reddit Terminal Viewer)")
451 (description
452 "RTV provides a text-based interface to view and interact with Reddit.")
453 (license (list license:expat
454 license:gpl3+)))) ; rtv/packages/praw
455
456 (define-public tuir
457 (package
458 (name "tuir")
459 (version "1.29.0")
460 (source
461 (origin
462 (method url-fetch)
463 (uri (pypi-uri "tuir" version))
464 (sha256
465 (base32
466 "06xb030ibphbrz4nsxm8mh3g60ld8xfp6kc3j6vi1k4ls5s4h79i"))))
467 (build-system python-build-system)
468 (arguments
469 `(#:phases
470 (modify-phases %standard-phases
471 (delete 'sanity-check) ; Tries to read environment variables.
472 (replace 'check
473 (lambda* (#:key tests? inputs outputs #:allow-other-keys)
474 (add-installed-pythonpath inputs outputs)
475 (when tests?
476 (invoke "pytest")))))))
477 (inputs
478 (list python-beautifulsoup4 python-decorator python-kitchen
479 python-requests python-six))
480 (native-inputs
481 (list python-coverage
482 python-coveralls
483 python-mock
484 python-pylint
485 python-pytest
486 python-vcrpy))
487 (home-page "https://gitlab.com/ajak/tuir")
488 (synopsis "Terminal viewer for Reddit (Terminal UI for Reddit)")
489 (description
490 "Tuir provides a simple terminal viewer for Reddit (Terminal UI for Reddit).")
491 (license (list license:expat
492 license:gpl3+)))) ; tuir/packages/praw
493
494 (define-public gfeeds
495 (package
496 (name "gfeeds")
497 (version "0.16.2")
498 (source (origin
499 (method url-fetch)
500 (uri
501 (string-append
502 "https://gitlab.gnome.org/World/gfeeds/-/archive/" version
503 "/gfeeds-" version ".tar.bz2"))
504 (sha256
505 (base32
506 "05gwwzqfz29m477imd5vh84jfla1wnklwpc2sdxnqli72wg08fli"))))
507 (build-system meson-build-system)
508 (arguments
509 `(#:phases
510 (modify-phases %standard-phases
511 (add-after 'unpack 'patch-mpv-path
512 (lambda* (#:key inputs #:allow-other-keys)
513 (substitute* "gfeeds/confManager.py"
514 (("mpv") (search-input-file inputs "/bin/mpv")))
515 #t))
516 (add-after 'unpack 'patch-webkit2-version
517 (lambda* (#:key inputs #:allow-other-keys)
518 (substitute* "bin/gfeeds.in"
519 (("gi\\.require_version\\('WebKit2', '4\\.0'\\)")
520 "gi.require_version('WebKit2', '4.1')"))))
521 (add-after 'install 'wrap-gfeeds
522 (lambda* (#:key outputs #:allow-other-keys)
523 (wrap-program (string-append
524 (assoc-ref outputs "out") "/bin/gfeeds")
525 `("PYTHONPATH" ":" prefix (,(getenv "GUIX_PYTHONPATH")))
526 `("GI_TYPELIB_PATH" ":" prefix (,(getenv "GI_TYPELIB_PATH")))
527 `("XDG_DATA_DIRS" ":" prefix (,(getenv "XDG_DATA_DIRS"))))
528 #t)))))
529 (native-inputs
530 `(("glib:bin" ,glib "bin")
531 ("gobject-introspection" ,gobject-introspection)
532 ("gtk+:bin" ,gtk+ "bin")
533 ("pkg-config" ,pkg-config)))
534 (inputs
535 (list glib
536 gsettings-desktop-schemas
537 gtk+
538 hicolor-icon-theme
539 libhandy
540 mpv
541 python
542 python-beautifulsoup4
543 python-dateutil
544 python-feedparser
545 python-html5lib
546 python-listparser
547 python-lxml
548 python-pillow
549 python-pygments
550 python-pytz
551 python-readability
552 python-requests
553 webkitgtk
554 python-pygobject))
555 (home-page "https://gfeeds.gabmus.org/")
556 (synopsis "Easy-to-use GTK+ RSS/Atom feed reader")
557 (description "Feeds is an RSS/Atom feed reader made with GTK+
558 and it has an easy-to-use graphical user interface.")
559 (license license:gpl3+)))