From 5d3419b6c3c4a137a4cf8eeb27e190feca9f4ed0 Mon Sep 17 00:00:00 2001 From: vitrinekast Date: Tue, 26 Mar 2024 14:35:31 +0100 Subject: [PATCH] filename --- create_book.sh | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/create_book.sh b/create_book.sh index ecd4973..a9349c6 100644 --- a/create_book.sh +++ b/create_book.sh @@ -1,6 +1,9 @@ -pandoc /home/xpub/www/html/tl-dr/book.html -o /home/xpub/www/html/tl-dr/logged_book.epub -c print.css --metadata title='TD;DR_' + $(date +'%B %dth %Y'), --epub-cover-image=cover.jpg --epub-embed-font='/home/xpub/www/html/tl-dr/fonts/Cascadia/ttf/CascadiaCode-Light.ttf' --epub-embed-font='/home/xpub/www/html/tl-dr/fonts/Ductus/DuctusRegular.woff' -cp /home/xpub/www/html/tl-dr/logged_book.epub /home/xpub/www/html/tl-dr/log-books/TDDR_$(date +'%B %dth %Y').epub -echo "did the overwrite" -ls log-books > log-books/all.txt - +#!/bin/bash +today=`date '+%B_%dth_%Y'`; +filename="TD;DR_$today" +echo $filename; +pandoc /home/xpub/www/html/tl-dr/book.html -o /home/xpub/www/html/tl-dr/logged_book.epub -c print.css --metadata title=$filename --epub-cover-image=cover.jpg --epub-embed-font='fonts/Cascadia/ttf/CascadiaCode-Light.ttf' --epub-embed-font='fonts/Ductus/DuctusRegular.woff' +cp /home/xpub/www/html/tl-dr/logged_book.epub /home/xpub/www/html/tl-dr/log-books/$filename.epub +echo "did the overwrite" +ls log-books > /home/xpub/www/html/tl-dr/log-books/all.txt \ No newline at end of file