After I crawled all the essays, I have done the following works:
- Design book cover
- Convert webpage encoding from cp1252 to utf-8 to prevent garbled characters
- Added three chapters: Favorite, Hackers and Painters, Latest
- Group essays alphabetically
- Add a few articles that are not original written by the author but are on the author's website(Richard Hamming, Donald E. Knuth...)
- Correct several punctuation mistakes (dashes and quotation marks) in the essays
- Delete 2 broken links, remove 1 obsolete essay with too short content
- Fix some unmatched tags in web pages to prevent text overflow on Kindles
If you are familiar with python and html, then you can add or remove essays/chapters easily! First, editing calibre.recipe or index.html, then follow the following steps:
git clone https://github.com/evmn/Paul-Graham.git
cd Paul-Graham
python -m http.server 8000
Debug your recipe with the following command:
ebook-convert calibre.recipe .mobi --test -vv --debug-pipeline debug
You can choose from Calibre and command line.
Open Calibre, right click Fetch news, then choose Add or edit a custom news source, click New recipe, then Switch to advanced mode and paste your recipe there, then click Save and choose Download this recipe. It takes less than a minute to make a Kindle books with local server.
You can also refer to this demo video in Telegram.
ebook-convert "calibre.recipe" .mobi \
--authors="Paul Graham" \
--title="Essays of Paul Graham" \
--pubdate="2021-10-24" \
--output-profile=kindle_pw3 \
--mobi-file-type=new \
-vv
- Footnotes link can't work properly