From d18fba2d2ea9f14a76b46cb81bcef7169314e124 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Fri, 27 Feb 2026 21:33:32 -0300 Subject: Fix: epub: minor changes, still disabled --- Makefile.bookup | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/Makefile.bookup b/Makefile.bookup index 5015ad8..58f5a90 100644 --- a/Makefile.bookup +++ b/Makefile.bookup @@ -180,29 +180,29 @@ bookdown_epub: @# EPUB format is broken right now @true - # Fix margin notes + @# Fix margin notes @#sed -e 's/r tufte::margin_note/marginfigure/' $(OUTPUT).md > $(OUTPUT).new && mv $(OUTPUT).new $(OUTPUT).md - # Build using bookdown::epub_book - # - # Broken due to the following issues: - # - # * https://github.com/rstudio/bookdown/issues/1179 - # * https://github.com/rstudio/bookdown/issues/1387 - # * https://github.com/rstudio/bookdown/blob/main/NEWS.md#major-changes - # + @# Build using bookdown::epub_book + @# + @# Broken due to the following issues: + @# + @# * https://github.com/rstudio/bookdown/issues/1179 + @# * https://github.com/rstudio/bookdown/issues/1387 + @# * https://github.com/rstudio/bookdown/blob/main/NEWS.md#major-changes + @# @#Rscript -e 'bookdown::render_book("$(OUTPUT).md", "bookdown::epub_book")' - # Build using bookdown::html_document2 + @# Build using bookdown::html_document2 @#Rscript -e 'bookdown::render_book("$(OUTPUT).md", "bookdown::html_document2")' - @#pandoc -f html -t epub3 -o $(OUTPUT).epub _main.html + @#pandoc --toc --toc-depth=2 -f html -t epub3 -o $(OUTPUT).epub _main.html - # Move + @# Move @##mv _book/_main.epub $(OUTPUT)/$(OUTPUT).epub @#mv _book/_main.epub $(OUTPUT_FOLDER)/$(OUTPUT).epub @#mv $(OUTPUT).epub $(OUTPUT_FOLDER)/$(OUTPUT).epub - # Cleanup + @# Cleanup @#rm -f _book/reference-keys.txt @#rmdir _book -- cgit v1.2.3