]> njoseph.me Git - blog.git/blame - content/posts/read-it-later-solution.md
Rolling my own Read It Later solution
[blog.git] / content / posts / read-it-later-solution.md
CommitLineData
27baf70d
JN
1---
2title: "Rolling my own Read It Later solution"
3date: 2020-09-18T23:51:09+05:30
4lastmod: 2020-09-18T20:40:09+05:30
5tags : [ "free-software", "Pocket", "Wallabag", "read-it-later", "Syncthing", "SingleFile", "Firefox", "addons" ]
6categories : [ "free-software", "privacy", "archiving" ]
7layout: post
8type: "post"
9highlight: false
10---
11
12After using Pocket (originally called Read It Later) and the self-hostable free software
13Wallabag, I [started wondering](https://toot.thoughtworks.com/@njoseph_1/104872980794830072)
14if this problem of archiving web pages to read later can be solved without
15having to use a web application.
16
17Pocket | Wallabag
18:-------------------------:|:-------------------------:
19![Pocket Logo](/blog/pocket.png) | ![Wallabag Logo](/blog/wallabag.png)
20
21Essentially, what I need is a way of saving the entire content of a web page for
22offline reading and maintain a list of such items. Also, I'd like the files to be
23available on multiple devices.
24
25![Why not Syncthing meme](/blog/why-not-syncthing.png)
26
27My go-to solution for making things available on multiple devices is [Syncthing](https://syncthing.net/ "Syncthing website").
28Syncthing is a file synchronization solution that allows synchronizing the files
29in one directory across multiple devices (a lot like rsync). Now the problem
30boils down to saving web pages as files.
31
32Most browsers allow you to save webpages. But webpages saved thus are not a
33single file, but a HTML file and a folder containing images, CSS files and
34other assets. There's fortunately a Firefox addon called
35[SingleFile](https://addons.mozilla.org/en-US/firefox/addon/single-file
36"SingleFile addon") which does exactly this. It allows you to save a webpage as
37a single HTML file by embedding the CSS, fonts, images etc.
38(Printing to PDF is another option, but I'm not a big fan of PDF files.)
39
40SingleFile | Syncthing
41:-------------------------:|:-------------------------:
42![SingleFile logo](/blog/singlefile.png) | ![Syncthing logo](/blog/syncthing.png)
43
44Firefox allows you to configure custom shortcuts for each extension. My
45preferred shortcut for saving a page for offline reading is Alt+C. You can also
46click on the SingleFile icon to save the current page.
47
48![SingleFile addon shortcut](/blog/singlefile-addon-shortcut.png)
49
50SingleFile doesn't provide an option to set the download directory but saves the
51file to the default download directory of the browser. I don't use the default
52download directory anyway, so I set it to `~/Sync/to-read`
53(`~/Sync` is the default directory synced by Syncthing). For other downloads,
54Firefox asks me where to save each download.
55
56![Firefox default download location](/blog/firefox-default-download.png)
57
58In the file manager, simply sort by "Last Modified" to see the latest saved items.
59
60![Sorting by last modified](/blog/last-modified.png)
61
62You can now read your pages completely offline - a feature which most
63read-it-later services cannot boast of!
64
65## Caveats
66
67* Browser performance might suffer when loading large pages saved by SingleFile.
68 Printing to PDF might be a better option in this case.
69* Firefox Reader View might not work on a saved page even if it had worked on the original page.
70
71## Acknowledgements
72
73Thanks to [@mathew@mastodon.social](https://mastodon.social/@mathew "Mathew's profile on mastodon.social") for suggesting the SingleFile addon.