Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not an Issue, but a guide to convert to epub #64

Open
DieselMeister opened this issue Mar 18, 2020 · 6 comments
Open

Not an Issue, but a guide to convert to epub #64

DieselMeister opened this issue Mar 18, 2020 · 6 comments

Comments

@DieselMeister
Copy link

DieselMeister commented Mar 18, 2020

It's not perfect, but for those who want'S to read it on a e-ink reader or something. M;aybe that helps.

  1. download pandoc (https://pandoc.org/)

  2. convert all images in the md-files to a proper md-format (I used notpad++)
    replace in all files:

    the images-tags
    (<resolved-image source=")(.*)(" />) to ![.$2]\(.$2\)

    the highlight-tags inside the code blocks
    \{highlight: \[.*\]\} to (empty-string)
    \{ highlight: \[.*\]\ } to (empty-string)
    \{\s*highlight:\s*\[.*\]\s*\} to (empty-string)

  3. use following script (state: 2020-03-18) (cmd for windows - sorry guys)

REM Please adjust the path for pandoc if needed

"C:\Program Files\Pandoc\pandoc" ^
-o the-elmisch-book.epub ^
.\title.txt ^
.\ReadMe.md ^
.\chapters\audience.md ^
.\chapters\overview.md ^
.\chapters\planned-chapters.md ^
.\chapters\contributing.md ^
.\chapters\acknowledgment.md ^
.\license.md ^
.\chapters\fable\readme.md ^
.\chapters\fable\hello-world.md ^
.\chapters\fable\development-mode.md ^
.\chapters\fable\counter.md ^
.\chapters\fable\observations.md ^
.\chapters\fable\compatibility.md ^
.\chapters\fable\fable-packages.md ^
.\chapters\fable\fable-bindings.md ^
.\chapters\fable\node-packages.md ^
.\chapters\fable\how-fable-works.md ^
.\chapters\elm\readme.md ^
.\chapters\elm\the-architecture.md ^
.\chapters\elm\counter.md ^
.\chapters\elm\render-html.md ^
.\chapters\elm\conditional-rendering.md ^
.\chapters\elm\using-css.md ^
.\chapters\elm\form-inputs.md ^
.\chapters\elm\react-in-elmish.md ^
.\chapters\elm\todo-app.md ^
.\chapters\elm\todo-app-part1.md ^
.\chapters\elm\todo-app-part2.md ^
.\chapters\elm\todo-app-part3.md ^
.\chapters\elm\todo-app-exercises.md ^
.\chapters\elm\project-structure.md ^
.\chapters\commands\readme.md ^
.\chapters\commands\commands.md ^
.\chapters\commands\definition.md ^
.\chapters\commands\async-updates.md ^
.\chapters\commands\async-to-cmd.md ^
.\chapters\commands\failing-async.md ^
.\chapters\commands\async-state.md ^
.\chapters\commands\deferred-module-utilities.md ^
.\chapters\commands\recursive-updates.md ^
.\chapters\commands\async-recursive-updates.md ^
.\chapters\commands\http.md ^
.\chapters\commands\xhr-elmish.md ^
.\chapters\commands\async-xhr.md ^
.\chapters\commands\working-with-json.md ^
.\chapters\commands\using-json.md ^
.\chapters\commands\elmish-hackernews.md ^
.\chapters\commands\elmish-hackernews-part1.md ^
.\chapters\commands\elmish-hackernews-part2.md ^
.\chapters\commands\elmish-hackernews-part3.md ^
.\chapters\commands\elmish-hackernews-exercises.md ^
.\chapters\scaling\readme.md ^
.\chapters\scaling\pages-as-programs.md ^
.\chapters\scaling\splitting-programs.md ^
.\chapters\scaling\integrating-commands.md ^
.\chapters\scaling\composition-forms.md ^
.\chapters\scaling\understanding-data-communication.md ^
.\chapters\scaling\intent.md ^
.\chapters\scaling\routing.md ^
.\chapters\scaling\parsing-url-segments.md ^
.\chapters\scaling\parsing-date-segments.md ^
.\chapters\scaling\programmatic-navigation.md ^
.\chapters\scaling\introducing-url-type.md ^
.\chapters\scaling\modelling-nested-routes.md ^
.\chapters\scaling\multi-page-routing.md ^
.\chapters\dev-flow\readme.md ^
.\chapters\dev-flow\webpack-mode.md ^
.\chapters\dev-flow\compiler-directives.md ^
.\chapters\dev-flow\configuration-variables.md ^
.\chapters\dev-flow\hot-module-replacement.md ^
.\chapters\dev-flow\understanding-webpack-loaders.md ^
.\chapters\dev-flow\static-images.md ^
.\chapters\dev-flow\styling-with-sass.md ^
.\chapters\dev-flow\introducing-femto.md

Update: had to adjust the highlight replace regex

@Zaid-Ajaj
Copy link
Owner

Hello there @DieselMeister. Thanks for the suggestion even I though I can't think of any good reason why someone would want to read this on anything but a browser: there are links to references, git repositories, animations and typos are fixed in real-time.

@DieselMeister
Copy link
Author

Hi. I am on the way to go to bed and I want to read this on my kindle :D So I decided to convert this for this reason and share the knowledge.

But you are right. With the references the best way is to read it in the browser.

@Zaid-Ajaj
Copy link
Owner

Well fair enough 😄 good night!

@melston
Copy link

melston commented May 25, 2020

Well, one reason for an epub/pdf version is that you can put it down and come back later to the same place you left off (ebook readers/acrobat remembers this information - browsers generally don't). But, it is static and you do lose out on the updated information when it is available.

@Thorium
Copy link

Thorium commented Sep 23, 2021

As there seems to be some epub users, could it be possible to link some old version to git repo?

Edit: For me, it's more like a bookmark: read these when you have some extra time. Easier to remember from Kindle / Google Books library where are all the other unread books and research papers. Libraries of web-links tend to expire and go missing.

@kodfodrasz
Copy link

kodfodrasz commented Dec 2, 2021

For me reading technical books in paper/ebook is more effective than in a browser: There are less distractions. If I get stuck I can still go to a computer to research the problem in question, but my method is usually reading up on the topic, gathering knowledge and context in a larger sprint, then later doing assignments, or practice or starting to use something in larger experiments in a larger batch/sprint.

Also the (e)book I have won't go 404, as Thorium noted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants