Skip to content

maennchen/cra-ebook

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

EU Cyber Resilience Act - Ebook

This project generates an EPUB ebook of the EU Cyber Resilience Act (Regulation (EU) 2024/2847) from the official Formex XML source.

Requirements

  • curl and unzip - for downloading the source
  • xsltproc - for XML transformation
  • pandoc - for EPUB generation

On NixOS/with devenv, simply run devenv shell to get all dependencies.

Usage

Download the Formex XML source and build the EPUB:

make formex   # Download source XML from EUR-Lex
make          # Build cra.epub

Or in one step (if formex directory doesn't exist):

make formex && make

To clean up generated files:

make clean

How It Works

  1. Source: The official Formex XML is downloaded from the EU Publications Office Cellar API
  2. Transform: XSLT transforms the XML to clean HTML with proper structure
  3. Convert: Pandoc converts the HTML to EPUB3 with embedded styles

Files

  • render.xslt - XSLT transformation from Formex XML to HTML
  • styles.css - Ebook styling
  • metadata.yaml - EPUB metadata (title, author, etc.)
  • Makefile - Build automation

License

The code in this repository (XSLT, CSS, Makefile, etc.) is licensed under the MIT License. See LICENSE for details.

The EU Cyber Resilience Act text itself is © European Union, 2024. According to EU policy, reuse is authorised provided the source is acknowledged.

Note: This repository only contains the transformation code, not the generated EPUB. You need to build the ebook yourself using the instructions above. I haven't investigated the legal situation around redistributing EU legislative documents and couldn't be bothered to figure it out.

About

The EU CRA as an ebook.

Topics

Resources

License

Stars

Watchers

Forks

Contributors