forked from smaclennan/get-comics
Get comics from the web
License
xdancho/get-comics
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
What is it? ----------- I read about 30 to 40 comics daily from the net. That is along with the comics in the newspaper. I wrote an Emacs lisp program to download them all for convenient viewing. However, when I go away on vacation, I wanted something to download the comics daily and save them. I had problems getting Emacs to startup and run reliably, so I quickly wrote the first get-comics. First get-comics ---------------- The first get-comics was a multi-threaded app that was driven by an xml file to download comics. I wrote it multi-threaded because I needed it fast. This was basically a prototype. It worked, but it tended to swamp the proxy server I used at the time. get-comics 2 ------------ The second version of get-comics is a single threaded version. Rather than spawning a thread per connection, it handles all the connections in a single thread using the `select' call. I find this version much more reliable than the multi-threaded version. It also has lower resource usage. This is the current version. get-comics 3 ------------ The third version of get-comics used libcurl. I found that libcurl hangs too often. Since the second version has been reliable for years, I basically dropped this version in favour of the second version. JSON Parsers ------------ I was using JSON at work and much preferred it to XML. I decided to convert get-comics to use JSON. get-comics went through three JSON parsers. I started with JSON lib. But it was an extra library dependency which is a pain on distros like Ubuntu that do not provide include files by default. So I decided to go with a source code version. I only needed a parser, not a full JSON library. I decided on js0n. I really like js0n. It is very small and fits nicely with the comics layout. Unfortunately, it is not portable to windows. So I finally decided on JSON_parser.c. It is portable. And it has the big plus that it tells you the exact character in the file the syntax error was on. Documentation ------------- The documentation for get-comics is either in man format (get-comics.1) or an HTML version (get-comics.html) There is a sample JSON file that I use: comics.json.
About
Get comics from the web
Resources
License
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published