From b7a7de19b4e39178f4241a2e8b9700387b30b0a3 Mon Sep 17 00:00:00 2001 From: crc Date: Fri, 25 Sep 2020 17:05:29 +0000 Subject: [PATCH] epub: other than the missing ncx file, it now passes validation FossilOrigin-Name: 2f66a6dd264cd2fbbf7c6dbd4d4228027899629e6a19faa61bf08d2dfd8b96f3 --- doc/book/general/retro-unu | 2 +- example/markdown-to-xhtml.retro | 4 +++- generate-epub.retro | 6 +++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/doc/book/general/retro-unu b/doc/book/general/retro-unu index 394d381..0befb00 100644 --- a/doc/book/general/retro-unu +++ b/doc/book/general/retro-unu @@ -39,7 +39,7 @@ As an example, This illustrates the format. Only code in the fenced blocks (between \~~~ pairs) get extracted and run. -(Note: this only applies to *source files*; fences are not used +(Note: this only applies to source files; fences are not used when entering code interactively). ## On The Name diff --git a/example/markdown-to-xhtml.retro b/example/markdown-to-xhtml.retro index 4aa5878..9fb1c1d 100755 --- a/example/markdown-to-xhtml.retro +++ b/example/markdown-to-xhtml.retro @@ -152,6 +152,7 @@ to deal with. @Emphasis n:zero? [ ' &Emphasis v:on ] [ ' &Emphasis v:off ] choose s:put ] case $\ [ &Escape v:on ] case + ASCII:SPACE [ sp ] case c:put ; :s:put [ format ] s:for-each ; @@ -305,7 +306,7 @@ some older RETRO source files. ~~~ :rule? dup [ '---- s:begins-with? ] [ '-+-+ s:begins-with? ] bi or ; -:format:rule drop '
s:put nl ; +:format:rule drop ' s:put nl ; ~~~ *Lists* @@ -423,3 +424,4 @@ listed at https://github.com/chriskempson/tomorrow-theme .h2 { font-size: 120%; } .h3 { font-size: 115%; } .h4 { font-size: 110%; } + .hr { display: block; height: 2px; background: #000000; } diff --git a/generate-epub.retro b/generate-epub.retro index 6878ef5..6390b52 100755 --- a/generate-epub.retro +++ b/generate-epub.retro @@ -94,7 +94,8 @@ Spine: ' file:s:put file:nl '__ file:s:put file:nl '____RETRO_Forth_:_User_Manual file:s:put file:nl -'____...bookid... file:s:put file:nl +'____works.forth.retro-manual file:s:put file:nl +'____en file:s:put file:nl '__ file:s:put file:nl '__ file:s:put file:nl @@ -105,10 +106,12 @@ drop '__ file:s:put file:nl #0 TOC [ drop dup '____ s:format file:s:put file:nl n:inc ] a:for-each drop '__ file:s:put file:nl +~~~ '__ file:s:put file:nl '__ file:s:put file:nl +~~~ ' file:s:put file:nl @FID file:close ~~~ @@ -145,5 +148,6 @@ Cleanup is the final step. Remove the temporary epub directory ~~~ 'STEP:_Cleanup s:put nl +'cp_-r_chapters_~/atua unix:system 'rm_-rf_epub_chapters unix:system ~~~