summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rw-r--r--_quarto.yml3
-rwxr-xr-xbin/svg+pdf+jpg.sh13
-rw-r--r--tryk/spiseseddel3.jpgbin916027 -> 0 bytes
-rw-r--r--tryk/spiseseddel3.pdfbin401359 -> 0 bytes
5 files changed, 17 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore
index 47c274c..ac3afc6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,2 +1,4 @@
/.quarto/
/_site/
+/tryk/spiseseddel3.pdf
+/tryk/spiseseddel3.jpg
diff --git a/_quarto.yml b/_quarto.yml
index d1cd6b3..828838d 100644
--- a/_quarto.yml
+++ b/_quarto.yml
@@ -1,8 +1,9 @@
project:
type: website
+ pre-render:
+ - bin/svg+pdf+jpg.sh tryk/spiseseddel3.svg
post-render:
- bin/pdfcompress.sh _site/tryk/oroeposten_3.pdf
-# - bin/pdfcompress.sh _site/tryk/spiseseddel3.pdf
website:
title: Orøposten
diff --git a/bin/svg+pdf+jpg.sh b/bin/svg+pdf+jpg.sh
new file mode 100755
index 0000000..9d6edc4
--- /dev/null
+++ b/bin/svg+pdf+jpg.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+set -eu
+
+INFILE=$1
+DIR=$(dirname "$INFILE")
+STEM=$(basename "$INFILE" .svg)
+
+[ -n "$QUARTO_PROJECT_RENDER_ALL" ] || exit
+
+inkscape --export-type=pdf,png --export-width=1800 "$INFILE"
+ffmpeg -hide_banner -loglevel warning -y -i "$DIR/$STEM.png" -update 1 -frames:v 1 "$DIR/$STEM.jpg"
+rm "$DIR/$STEM.png"
diff --git a/tryk/spiseseddel3.jpg b/tryk/spiseseddel3.jpg
deleted file mode 100644
index 754b6a5..0000000
--- a/tryk/spiseseddel3.jpg
+++ /dev/null
Binary files differ
diff --git a/tryk/spiseseddel3.pdf b/tryk/spiseseddel3.pdf
deleted file mode 100644
index a588f24..0000000
--- a/tryk/spiseseddel3.pdf
+++ /dev/null
Binary files differ