Padding for pipes and line continuation backslashes
This commit is contained in:
parent
3b3c4fdfc9
commit
f6ed4c5757
|
@ -89,12 +89,12 @@ mkdir -p -- "${OUTDIR}" || {
|
||||||
# https://www.ietf.org/rfc/rfc2396.txt
|
# https://www.ietf.org/rfc/rfc2396.txt
|
||||||
# 2.4.3. Excluded US-ASCII Characters
|
# 2.4.3. Excluded US-ASCII Characters
|
||||||
m3u8_manifest_urls_and_metadata="$(
|
m3u8_manifest_urls_and_metadata="$(
|
||||||
wget --no-verbose \
|
wget --no-verbose \
|
||||||
--quiet \
|
--quiet \
|
||||||
--output-document - \
|
--output-document - \
|
||||||
--header="authorization: Bearer ${BASE64_BEARER_TOKEN}" \
|
--header="authorization: Bearer ${BASE64_BEARER_TOKEN}" \
|
||||||
-- "${API_URL}" |
|
-- "${API_URL}" |
|
||||||
jq --raw-output \
|
jq --raw-output \
|
||||||
'.value[] | .name + ">" + .media.duration[2:] + ">" + (.playbackUrls | map(select(.mimeType == "application/vnd.apple.mpegurl")) | .[].playbackUrl)'
|
'.value[] | .name + ">" + .media.duration[2:] + ">" + (.playbackUrls | map(select(.mimeType == "application/vnd.apple.mpegurl")) | .[].playbackUrl)'
|
||||||
)"
|
)"
|
||||||
|
|
||||||
|
@ -127,8 +127,8 @@ do
|
||||||
-progress - \
|
-progress - \
|
||||||
-c copy \
|
-c copy \
|
||||||
"${filepath}" |
|
"${filepath}" |
|
||||||
grep --line-buffered 'out_time=' |
|
grep --line-buffered 'out_time=' |
|
||||||
sed -u -e 's/out_time=//g' -e 's/\..*//g' -e 's/^-//g' |
|
sed -u -e 's/out_time=//g' -e 's/\..*//g' -e 's/^-//g' |
|
||||||
xargs -I{} printf '%s\r' "{} of ${length} "
|
xargs -I{} printf '%s\r' "{} of ${length} "
|
||||||
|
|
||||||
printf '\n\033[33m%s\033[m\n' "Done"
|
printf '\n\033[33m%s\033[m\n' "Done"
|
||||||
|
|
Loading…
Reference in New Issue