Put titles on each file, because the big file title won't work well

This commit is contained in:
Nemo 2020-04-08 03:36:09 +05:30
parent 42f699c8a9
commit 8cfeea8ea9
2 changed files with 2 additions and 1 deletions

View File

@ -2,6 +2,7 @@
set -euo pipefail
export CF_DNS_SERVERS='1.1.1.1 9.9.9.9'
export CF_SETTLE_TIME='30'
# Based on https://gist.github.com/benkulbertis/fff10759c2391b6618dd/
export CF_KEY=$(pass show Keys/CF_KEY)

View File

@ -50,7 +50,7 @@ while read -r first _ _ start _ end; do
FILENAME="${CHAPTER_INDEX_PADDED} - $(trim "$CHAPTER_TITLE").m4a"
ffmpeg -vsync 2 -i "$1" -ss "${start%?}" -to "$end" -vn -acodec copy "$FILENAME" </dev/null
ffmpeg -vsync 2 -i "$1" -ss "${start%?}" -to "$end" -vn -metadata title="$CHAPTER_TITLE" -acodec copy "$FILENAME" </dev/null
((CHAPTER_INDEX++))
fi