diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1a94ff0e..896010cf 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,14 +14,17 @@ jobs: - name: Install dependencies run: | sudo apt-get --assume-yes update - sudo apt-get --assume-yes install pandoc texlive-xetex + sudo apt-get --assume-yes install pandoc texlive-xetex texinfo - name: Build ebooks - run: make + run: make pdf epub info - name: Pub uses: actions/upload-artifact@v4 with: name: r2book - path: r2book.* + path: | + r2book.pdf + r2book.epub + r2book.info.gz # Release creation check_release: @@ -70,4 +73,7 @@ jobs: draft: false prerelease: false generate_release_notes: true - files: r2book.* + files: | + r2book.pdf + r2book.epub + r2book.info.gz diff --git a/.gitignore b/.gitignore index 9c7a6b3d..839cebb2 100644 --- a/.gitignore +++ b/.gitignore @@ -15,3 +15,5 @@ _book/* *.log r2book.pdf r2book.epub +r2book.texi +r2book.info* diff --git a/Makefile b/Makefile index 15b301d3..3d46f627 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ all: pdf epub -.PHONY: epub pdf pdf_old gmi +.PHONY: epub pdf pdf_old gmi texi info pdf_old: node_modules npm run build @@ -31,6 +31,15 @@ pdf: epub: pandoc $(CHAPTERS) $(PANDOC_OPTIONS) $(PANDOC_EPUB_OPTIONS) -o r2book.epub +texi: + pandoc $(CHAPTERS) $(PANDOC_OPTIONS) -o r2book.texi + sed -i -E 's,@uref\{[0-9a-z/_-]+gemini://,@uref\{gemini://,gI' r2book.texi # fix gemini link + +info: texi + rm -f r2book.info r2book.info.gz + makeinfo --force --no-split r2book.texi + gzip -9n r2book.info + MD2GMI=md2gmi/md2gmi md2gmi: