From ce94f3ee8eb21aba0649d1a811a9fc84ec851082 Mon Sep 17 00:00:00 2001 From: Luke Bubar <43391582+lukerb52@users.noreply.github.com> Date: Thu, 28 May 2020 07:10:48 -0400 Subject: [PATCH 1/2] Added epub, cbz, and cbr support to lf (#655) * Added `epub` support to the `lfrc` * Update lfrc --- .config/lf/lfrc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.config/lf/lfrc b/.config/lf/lfrc index f07b8d4..13c46eb 100644 --- a/.config/lf/lfrc +++ b/.config/lf/lfrc @@ -22,6 +22,9 @@ cmd open ${{ audio/*) mpv --audio-display=no $f ;; video/*) setsid mpv $f -quiet >/dev/null 2>&1 & ;; application/pdf) setsid zathura $fx >/dev/null 2>&1 & ;; + application/epub+zip) setsid zathura $fx >/dev/null 2>&1 & ;; + application/vnd.comicbook+zip) setsid zathura $fx >/dev/null 2>&1 & ;; + application/vnd.comicbook-rar) setsid zathura $fx >/dev/null 2>&1 & ;; *) for f in $fx; do setsid $OPENER $f >/dev/null 2>&1 & done;; esac }} From 09a773e81d38697172a8135414e2ebdbf7ad3164 Mon Sep 17 00:00:00 2001 From: Jaime Lopez Date: Fri, 29 May 2020 10:37:15 -0700 Subject: [PATCH 2/2] adds 2 digits for last track for cases when less than 10 tracks (#660) --- .local/bin/booksplit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.local/bin/booksplit b/.local/bin/booksplit index 0029d0b..3d0ab07 100755 --- a/.local/bin/booksplit +++ b/.local/bin/booksplit @@ -39,6 +39,6 @@ do done < "$2" # The last track must be done outside the loop. echo "From $start to the end: $title" -file="$escbook/$track-$esctitle.$ext" +file="$escbook/$(printf "%.2d" "$track")-$esctitle.$ext" echo "Splitting \"$title\"..." && ffmpeg -nostdin -y -loglevel -8 -i "$inputaudio" -ss "$start" -vn "$file" && echo "Tagging \"$title\"..." && tag -a "$author" -A "$booktitle" -t "$title" -n "$track" -N "$total" -d "$year" "$file"