diff --git a/burnSubs b/burnSubs
old mode 100644
new mode 100755
index 6b44de0..f019935
--- a/burnSubs
+++ b/burnSubs
@@ -5,12 +5,11 @@ set -o errexit
################################################################################
# burnSubs
-# version 0.9.1
+# version 0.9.2
#################3
# Wishlist:
# queue encodes
# finish TODOs
-# list subtitles flag
# finish help flag
# audio recode flag
################################################################################
@@ -48,7 +47,7 @@ function machineSetup() {
if [[ "$(hostname)" == "Kusanagi" ]]; then
echo " > Hostname: 草薙素子"
export OPTS_ENC="nvidia"
- echo "FIX FFMPEG!"
+ echo "---> FIX FFMPEG!"
#export FFMPEG="/opt/ffmpeg-nvenc/bin/ffmpeg"
export LD_LIBRARY_PATH="/opt/ffmpeg-nvenc/lib"
export FF_EXT="${FF_EXT} -pix_fmt yuv420p"
@@ -312,7 +311,9 @@ function selectSubs() {
# TODO: handle multiple subtitle files
# TODO: verify the the subtitle index is legal
if [[ $SUB_COUNT -eq 0 ]]; then
- echo " > ERROR: No subtitles! Todo!"
+ echo " > ERROR: No subtitles!"
+ echo " > Reverting to a dry run."
+ export OPTS_DRYRUN=true
export SUBTITLE_INDEX=-1
else
if [[ $OPTS_SELSUB -lt 0 && $SUB_COUNT -gt 1 ]]; then
@@ -343,8 +344,13 @@ function selectSubs() {
function extractSubs() {
- echo " > extracting subtitles"
export SUBTITLE_FILE="${TMP}/ripped.ass"
+ if [[ $SUBTITLE_INDEX -lt 0 ]]; then
+ echo " > skipping subtitles (TODO: tidy cleanup)"
+ return
+ else
+ echo " > extracting subtitles"
+ fi
extractIndex="$1"
"$FFMPEG" -i "${INPUT_VIDEO}" -map 0:"${extractIndex}" -vn -an -c:s copy -c:a copy \
"$SUBTITLE_FILE" 2>/dev/null
@@ -522,7 +528,26 @@ while true; do
"-h" | "--help")
# TODO: Display help
shift # all arguments parsed
- echo "TODO: HELP!" # Display HELP
+ echo "$(basename $0) [args]