Moving modules into a new modules directory. Adding installation instructions to fascilitate offline installation.

This commit is contained in:
Roland 2023-11-23 16:17:04 -07:00
parent 322e0e1bd8
commit a2c4aee9ad
No known key found for this signature in database
GPG key ID: 1BA620CE6C9A4680
24 changed files with 69 additions and 7 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 112 KiB

View file

@ -0,0 +1,38 @@
# Archive Files
WROLPi creates several files when archiving a webpage:
1. A [Singlefile](index.md#singlefile) that stores an exact copy of the web page.
2. A [Readability](index.md#readability) file.
3. A Readability text file.
4. A Readability JSON file.
5. A screenshot file of the web page.
These files all share the same filename but have different suffixes.
| File Suffix | Purpose |
|-------------------|--------------------------------------------|
| .html | The Singlefile. |
| .readability.html | The Readability extract of the Singlefile. |
| .readability.txt | The article text extracted by Readability. |
| .readability.json | Data from Readability (URL/author/etc.). |
| .png | The screenshot of the web page. |
Archive files are named using three parts:
1. The domain directory.
2. The archive date time (YYYY-MM-DD-HH-MM-SS).
3. The title of the web page.
If archiving `https://wrolpi.org/getting-started`, the resulting files might be named as follows:
```
wrolpi.org/2023-01-01-12-00-00_Getting Started.html
wrolpi.org/2023-01-01-12-00-00_Getting Started.readability.html
wrolpi.org/2023-01-01-12-00-00_Getting Started.readability.txt
wrolpi.org/2023-01-01-12-00-00_Getting Started.readability.json
wrolpi.org/2023-01-01-12-00-00_Getting Started.png
```
WROLPi will attempt to extract the Readability and create a screenshot from the Singlefile. If this is not possible,
WROLPi will still keep the lone Singlefile.

View file

@ -0,0 +1,44 @@
# Archives
The Archives module allows for viewing, organizing, and downloading webpages as SingleFile files. Each Archive's URL is
retained and organized by domain in the Domains tab. The Archives page (`/archive`) sorts entries by the most recently
published articles.
In the context of WROLPi, an Archive refers to a set of [similarly named files](files.md) created while archiving.
A single SingleFile file is also supported.
![An Archive page](archive-page.png)
## Singlefile
A [Singlefile](https://github.com/gildas-lormeau/SingleFile) is an HTML file which contains encoded copies of all files
necessary to render a webpage. Normally, a webpage will link to many resources outside the page you are viewing, which
causes problems when you attempt to save the webpage because you will need to download and organize all these files.
Singlefile solves this problem by encoding and embedding all the related files within a single HTML file.
The Singlefile project has many advantages:
* It creates a single HTML file that can be easily shared with others.
* All that is necessary to view the archive is a compatible browser; no external files or services are needed.
* It provides an exact copy that handles the rendering of Javascript the page contains.
* Images and style are preserved.
## Readability
[Readability](https://github.com/mozilla/readability) is a Mozilla project which extracts the article from a web page.
Because a web page comprises many HTML, CSS, and Javascript elements that we do not want to search, WROLPi uses
Readability to extract the words that will be indexed.
![A preview of the Readability extract of wrolpi.org](readability-preview.png)
## Domain
A domain is the host of the archived URL. For example, the host of `https://wrolpi.org/getting-started` is `wrolpi.org`.
## Searching
When the indexes for an Archive are generated for searching, they are searched in the following order of precedence:
1. Title
2. HTML Metadata Description
3. Readability Text

Binary file not shown.

After

Width:  |  Height:  |  Size: 82 KiB