Last active
August 4, 2020 12:51
-
-
Save tanho63/97adf9cc84d2ff97d150c72cbdc52e0c to your computer and use it in GitHub Desktop.
Build bookdown as epub
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#### Convert bookdown to epub #### | |
library(devtools) | |
## Clone to folder | |
book_repo <- "hadley/adv-r" | |
dest_folder <- "~/documents/github" | |
usethis::create_from_github(book_repo,dest_folder,TRUE,protocol = "https") | |
# (Now manually open the .rproj file) | |
## Install packages | |
devtools::install_deps() # cross fingers and apply debug where necessary | |
## Bookdown to epub | |
bookdown::render_book(input = "index.rmd", output_format = bookdown::epub_book()) # cross fingers (and prepare pest control) | |
# epub should appear somewhere (_book in this case, I think) after it builds all the way |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment