Download articles for offline viewing as simple HTML, themed html, epub or markdown.
Go to file
lee2sman 6b3269ff6f add screenshot of reader view 2021-07-21 02:47:33 -04:00
epubs initial commit 2021-07-20 19:08:29 -04:00
lib add comments 2021-07-20 17:19:49 -04:00
markdown initial commit 2021-07-20 19:08:29 -04:00
originals initial commit 2021-07-20 19:08:29 -04:00
reader initial commit 2021-07-20 19:08:29 -04:00
themes add now.css 2021-07-20 22:34:11 -04:00
.gitignore add .gitignore 2021-07-20 20:16:09 -04:00
README.md add screenshot of reader view 2021-07-21 02:47:03 -04:00
bookmobile.fish switched backend to readability-cli rather than roll my own 2021-07-20 19:04:39 -04:00
converted-nyt.jpg add screenshot of reader view 2021-07-21 02:47:03 -04:00
nyt-medium.jpg add screenshot of reader view 2021-07-21 02:47:33 -04:00

README.md

Bookmobile

Simple command line script to download articles for offline viewing as markdown, simplified clean HTML and epub.

This is a fishscript (shell) gluing together pandoc and a Node.js package that implements the Firefox reader view. It uses a NPM package that uses Mozilla's own reability javascript. If that's not the right solution for you, jump down to the alternatives section at the end.

rendered NYTimes article
Example New York Times article rendered in the reader view with the 'Medium' theme

Dependencies

  • fish
  • Pandoc
  • Node.js / NPM

Note: you must have the following sub-directories: originals/ reader/ epubs/ markdown/

Install

npm install readability-cli
git clone https://tildegit.org/exquisitecorp/bookmobile.git
cd bookmobile
chmod +x bookmobile.fish

Usage

./bookmobile.fish URL

Output:

A simplified HTML document will be saved to originals. A reader view with chosen (or default) theme will be saved to reader/. An epub in epubs/ and a markdown file to markdown sub-directory.

To change themes

The themes subdirectory contains several custom simple themes for rendering a nice reader view. You can edit these or add your own custom theme to this folder. Change the theme selection in line 3 of the bookmobile.fish file.

Alternatives

Currently there are a number of CLI programs that are ports of the Readability project. These may serve your needs better.

A partial listing can be found here