mirror of
https://github.com/ebrandi/FDD-book.git
synced 2026-12-06 00:23:30 +00:00
Update the files needed to generate the .pdf and .epub
This commit is contained in:
parent
f92af5b969
commit
42a979a40e
4 changed files with 23 additions and 23 deletions
|
|
@ -56,10 +56,10 @@ sudo apt install -y software-properties-common apt-transport-https ca-certificat
|
|||
```bash
|
||||
# Download the latest pandoc version for Ubuntu
|
||||
cd /tmp
|
||||
wget https://github.com/jgm/pandoc/releases/latest/download/pandoc-3.1.11-1-amd64.deb
|
||||
wget https://github.com/jgm/pandoc/releases/download/3.9.0.2/pandoc-3.9.0.2-1-amd64.deb
|
||||
|
||||
# Install the downloaded package
|
||||
sudo dpkg -i pandoc-3.1.11-1-amd64.deb
|
||||
sudo dpkg -i pandoc-3.9.0.2-1-amd64.deb
|
||||
|
||||
# If you get dependency errors, fix them
|
||||
sudo apt --fix-broken install -y
|
||||
|
|
@ -68,7 +68,7 @@ sudo apt --fix-broken install -y
|
|||
pandoc --version
|
||||
|
||||
# Clean up
|
||||
rm -f pandoc-3.1.11-1-amd64.deb
|
||||
rm -f pandoc-3.9.0.2-1-amd64.deb
|
||||
```
|
||||
|
||||
#### 3. **LaTeX Distribution Installation** (with XeLaTeX support)
|
||||
|
|
@ -210,17 +210,17 @@ mkdir -p ~/.local/share/pandoc/templates
|
|||
# Navigate to the templates directory
|
||||
cd ~/.local/share/pandoc/templates
|
||||
|
||||
# Download the latest Eisvogel template (version 3.2.0)
|
||||
wget https://github.com/Wandmalfarbe/pandoc-latex-template/releases/download/v3.2.0/Eisvogel-3.2.0.tar.gz
|
||||
# Download the latest Eisvogel template (version 3.4.0)
|
||||
wget https://github.com/Wandmalfarbe/pandoc-latex-template/releases/download/v3.4.0/Eisvogel-3.4.0.tar.gz
|
||||
|
||||
# Extract the downloaded archive
|
||||
tar -xzf Eisvogel-3.2.0.tar.gz
|
||||
tar -xzf Eisvogel-3.4.0.tar.gz
|
||||
|
||||
# Copy the main template file to the templates directory
|
||||
cp Eisvogel-3.2.0/eisvogel.latex ./
|
||||
cp Eisvogel-3.4.0/eisvogel.latex ./
|
||||
|
||||
# Clean up temporary files
|
||||
rm -rf Eisvogel-3.2.0 Eisvogel-3.2.0.tar.gz
|
||||
rm -rf Eisvogel-3.4.0 Eisvogel-3.4.0.tar.gz
|
||||
|
||||
# Verify the template is properly installed
|
||||
ls -la eisvogel.latex
|
||||
|
|
@ -595,14 +595,14 @@ ls -la eisvogel.latex
|
|||
cp eisvogel.latex eisvogel.latex.backup
|
||||
|
||||
# Download latest version
|
||||
wget https://github.com/Wandmalfarbe/pandoc-latex-template/releases/latest/download/Eisvogel-3.2.0.tar.gz
|
||||
wget https://github.com/Wandmalfarbe/pandoc-latex-template/releases/download/v3.4.0/Eisvogel-3.4.0.tar.gz
|
||||
|
||||
# Extract and install
|
||||
tar -xzf Eisvogel-3.2.0.tar.gz
|
||||
cp Eisvogel-3.2.0/eisvogel.latex ./
|
||||
tar -xzf Eisvogel-3.4.0.tar.gz
|
||||
cp Eisvogel-3.4.0/eisvogel.latex ./
|
||||
|
||||
# Clean up
|
||||
rm -rf Eisvogel-3.2.0 Eisvogel-3.2.0.tar.gz
|
||||
rm -rf Eisvogel-3.4.0 Eisvogel-3.4.0.tar.gz
|
||||
|
||||
# Test the new template
|
||||
cd ~/your-project-directory
|
||||
|
|
@ -704,7 +704,7 @@ pandoc $(find content/ -name "*.md" | sort) \
|
|||
--to=html5 \
|
||||
--standalone \
|
||||
--embed-resources \
|
||||
--highlight-style=tango \
|
||||
--syntax-highlighting=tango \
|
||||
--toc \
|
||||
--toc-depth=2 \
|
||||
--number-sections \
|
||||
|
|
@ -713,7 +713,7 @@ pandoc $(find content/ -name "*.md" | sort) \
|
|||
--metadata date="DRAFT Version 1.0 - August, 30th 2025" \
|
||||
-o public/downloads/freebsd-device-drivers.html
|
||||
|
||||
**Note**: The `--highlight-style=tango` option provides excellent C language syntax highlighting. Other available styles include: `pygments`, `kate`, `espresso`, `zenburn`, `monochrome`, `breezedark`, and `haddock`. You can list all available styles with `pandoc --list-highlight-styles`.
|
||||
**Note**: The `--syntax-highlighting=tango` option (new name for the deprecated `--highlight-style` flag in recent Pandoc releases) provides excellent C language syntax highlighting. Other available styles include: `pygments`, `kate`, `espresso`, `zenburn`, `monochrome`, `breezedark`, and `haddock`. You can list all available styles with `pandoc --list-highlight-styles`.
|
||||
```
|
||||
|
||||
### HTML5 vs PDF Comparison
|
||||
|
|
@ -742,7 +742,7 @@ If you encounter issues:
|
|||
|
||||
1. Check the troubleshooting section above
|
||||
2. Verify all prerequisites are installed
|
||||
3. Check the Eisvogel documentation in `Eisvogel-3.2.0/README.md`
|
||||
3. Check the Eisvogel documentation in `Eisvogel-3.4.0/README.md`
|
||||
|
||||
The build system is designed to be robust and provide clear error messages to help resolve any issues quickly.
|
||||
|
||||
|
|
@ -820,4 +820,4 @@ This section documents known problems and limitations that exist in the current
|
|||
- Contribute improvements to the build system
|
||||
- Share workarounds and best practices
|
||||
|
||||
**Note**: These limitations are documented to set realistic expectations and help users work around known problems. The build system is functional for most use cases, but awareness of these limitations helps in planning and content preparation.
|
||||
**Note**: These limitations are documented to set realistic expectations and help users work around known problems. The build system is functional for most use cases, but awareness of these limitations helps in planning and content preparation.
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ cd "$ROOT_DIR"
|
|||
# Book information
|
||||
BOOK_TITLE="FreeBSD Device Drivers"
|
||||
BOOK_AUTHOR="Edson Brandi"
|
||||
BOOK_DATE="DRAFT Version 1.2 - November 1, 2025"
|
||||
BOOK_DATE="Version 2.0 - April, 22th 2026"
|
||||
|
||||
# File paths
|
||||
TITLE_FILE="$SCRIPT_DIR/title.md"
|
||||
|
|
@ -312,7 +312,7 @@ build_pdf() {
|
|||
--variable code-block-font-size=\\footnotesize \
|
||||
--variable float-placement-figure="H" \
|
||||
--variable figure-placement="H" \
|
||||
--highlight-style=tango \
|
||||
--syntax-highlighting=tango \
|
||||
--variable linestretch=1.15 \
|
||||
--variable geometry:"inner=2cm,outer=2cm,top=2.5cm,bottom=2.5cm" \
|
||||
-o "$OUTPUT_DIR/freebsd-device-drivers.pdf" 2>&1
|
||||
|
|
@ -364,7 +364,7 @@ build_epub() {
|
|||
--toc \
|
||||
--toc-depth=2 \
|
||||
--number-sections \
|
||||
--highlight-style=tango \
|
||||
--syntax-highlighting=tango \
|
||||
--epub-chapter-level=1 \
|
||||
--verbose \
|
||||
-o "$OUTPUT_DIR/freebsd-device-drivers.epub" 2>&1
|
||||
|
|
@ -423,7 +423,7 @@ build_html() {
|
|||
--to=html5 \
|
||||
--standalone \
|
||||
--embed-resources \
|
||||
--highlight-style=tango \
|
||||
--syntax-highlighting=tango \
|
||||
--toc \
|
||||
--toc-depth=2 \
|
||||
--number-sections \
|
||||
|
|
|
|||
|
|
@ -15,8 +15,8 @@
|
|||
# Core document metadata that appears in the title page and document properties
|
||||
#title: "FreeBSD Device Drivers"
|
||||
subtitle: "From First Steps to Kernel Mastery"
|
||||
#author: "Edson Brandi"
|
||||
#date: "DRAFT Version 1.0 - August, 30th 2025"
|
||||
author: "Edson Brandi"
|
||||
date: "Version 2.0 - April, 22th 2026"
|
||||
|
||||
# =============================================================================
|
||||
# DOCUMENT CLASSIFICATION AND METADATA
|
||||
|
|
|
|||
|
|
@ -2,6 +2,6 @@
|
|||
title: "FreeBSD Device Drivers"
|
||||
subtitle: "From First Steps to Kernel Mastery"
|
||||
author: "Edson Brandi"
|
||||
date: "DRAFT Version 1.0 - August, 30th 2025"
|
||||
date: "Version 2.0 - April, 22th 2026"
|
||||
---
|
||||
\newpage
|
||||
|
|
|
|||
Loading…
Reference in a new issue