initial commit

This commit is contained in:
lee2sman 2021-07-20 19:08:29 -04:00
parent c2cae799b9
commit 70213b0530
4 changed files with 546 additions and 0 deletions

BIN
epubs/bookmobile.epub Normal file

Binary file not shown.

97
markdown/bookmobile.md Normal file
View File

@ -0,0 +1,97 @@
bookmobile
==========
exquisitecorp
------------------------------------------------------------------------
An attempt at building my own offline article collector. In progress.
[]()
You can not select more than 25 topics Topics must start with a letter
or number, can include dashes ('-') and can be up to 35 characters long.
![](https://tildegit.org/avatars/6b068f4f161a778ab36bcdb68fa37302?size=48 "exquisitecorp")
[**lee2sman**](https://tildegit.org/exquisitecorp)
[c2cae799b9](https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9)
[switched backend to readability-cli rather than roll my
own](https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9)
3 minutes ago
[lib](https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/lib "lib")
[add
comments](https://tildegit.org/exquisitecorp/bookmobile/commit/84532321282d4c7b54994e7bc05692420893b805 "add comments")
2 hours ago
[themes](https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/themes "themes")
[initial
commit](https://tildegit.org/exquisitecorp/bookmobile/commit/fd4e58e425482442be67465cb48838e157c3407e "initial commit")
2 hours ago
[README.md](https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/README.md "README.md")
[update
README.md](https://tildegit.org/exquisitecorp/bookmobile/commit/24a34721d653d45e75bf35b14cd4e01b9f6470b5 "update README.md")
6 minutes ago
[bookmobile.fish](https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/bookmobile.fish "bookmobile.fish")
[switched backend to readability-cli rather than roll my
own](https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9 "switched backend to readability-cli rather than roll my own")
3 minutes ago
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.
### 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](https://github.com/masukomi/arc90-readability#readability-10)

217
originals/bookmobile.html Normal file
View File

@ -0,0 +1,217 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="chrome://global/skin/aboutReader.css" type="text/css">
<title>bookmobile</title>
</head>
<body class="light sans-serif loaded" style="--font-size:14pt; --content-width:40em;">
<div class="container" >
<div class="header reader-header reader-show-element">
<h1 class="reader-title">bookmobile</h1>
<div class="credits reader-credits">exquisitecorp</div>
</div>
<hr>
<div class="content">
<div class="moz-reader-content reader-show-element">
<div class="page" id="readability-page-1"><div>
<div>
<p><span>An attempt at building my own offline article collector. In progress.</span>
<a href=""></a>
</p>
</div>
<p><span id="count_prompt">You can not select more than 25 topics</span>
<span id="format_prompt">Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.</span>
</p>
<table id="repo-files-table">
<thead>
<tr>
<th colspan="2">
<img height="24" width="24" title="exquisitecorp" src="https://tildegit.org/avatars/6b068f4f161a778ab36bcdb68fa37302?size=48">
<a href="https://tildegit.org/exquisitecorp"><strong>lee2sman</strong></a>
<a href="https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9" rel="nofollow">
<span>c2cae799b9</span>
</a>
<a>
</a>
<span title="switched backend to readability-cli rather than roll my own"><span><a href="https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9">switched backend to readability-cli rather than roll my own</a></span>
</span>
</th>
<th><span title="Tue, 20 Jul 2021 23:04:39 UTC">3 minutes ago</span></th>
</tr>
</thead>
<tbody>
<tr>
<td>
<span>
<a title="lib" href="https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/lib">
lib
</a>
</span>
</td>
<td>
<span>
<a title="add comments" href="https://tildegit.org/exquisitecorp/bookmobile/commit/84532321282d4c7b54994e7bc05692420893b805">add comments</a>
</span>
</td>
<td><span title="Tue, 20 Jul 2021 21:19:49 UTC">2 hours ago</span></td>
</tr>
<tr>
<td>
<span>
<a title="themes" href="https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/themes">
themes
</a>
</span>
</td>
<td>
<span>
<a title="initial commit" href="https://tildegit.org/exquisitecorp/bookmobile/commit/fd4e58e425482442be67465cb48838e157c3407e">initial commit</a>
</span>
</td>
<td><span title="Tue, 20 Jul 2021 21:11:49 UTC">2 hours ago</span></td>
</tr>
<tr>
<td>
<span>
<a title="README.md" href="https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/README.md">README.md</a>
</span>
</td>
<td>
<span>
<a title="update README.md" href="https://tildegit.org/exquisitecorp/bookmobile/commit/24a34721d653d45e75bf35b14cd4e01b9f6470b5">update README.md</a>
</span>
</td>
<td><span title="Tue, 20 Jul 2021 23:01:22 UTC">6 minutes ago</span></td>
</tr>
<tr>
<td>
<span>
<a title="bookmobile.fish" href="https://tildegit.org/exquisitecorp/bookmobile/src/branch/master/bookmobile.fish">bookmobile.fish</a>
</span>
</td>
<td>
<span>
<a title="switched backend to readability-cli rather than roll my own" href="https://tildegit.org/exquisitecorp/bookmobile/commit/c2cae799b9416a604e05a1004291ff5831a9a8d9">switched backend to readability-cli rather than roll my own</a>
</span>
</td>
<td><span title="Tue, 20 Jul 2021 23:04:39 UTC">3 minutes ago</span></td>
</tr>
</tbody>
</table>
<div>
<p>Simple command line script to download articles for offline viewing as markdown, simplified clean HTML and epub.</p>
<p>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.</p>
<h3 id="user-content-dependencies">Dependencies</h3>
<ul>
<li>fish</li>
<li>Pandoc</li>
<li>Node.js / NPM</li>
</ul>
<p>Note: you must have the following sub-directories: originals/ reader/ epubs/ markdown/</p>
<h3 id="user-content-install">Install</h3>
<pre><code>npm install readability-cli
git clone https://tildegit.org/exquisitecorp/bookmobile.git
cd bookmobile
chmod +x bookmobile.fish
</code></pre><h3 id="user-content-usage">Usage</h3>
<pre><code>./bookmobile.fish URL
</code></pre><p>Output:</p>
<p>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.</p>
<h3 id="user-content-to-change-themes">To change themes</h3>
<p>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.</p>
<h3 id="user-content-alternatives">Alternatives</h3>
<p>Currently there are a number of CLI programs that are ports of the Readability project. These may serve your needs better.</p>
<p>A partial listing can be found <a rel="nofollow" href="https://github.com/masukomi/arc90-readability#readability-10">here</a></p>
</div>
</div></div>
</div>
</div>
</div>
</body></html>

232
reader/bookmobile.html Normal file

File diff suppressed because one or more lines are too long