From 8e3b56c06ebdc57739ea1d45b91c720153303dc4 Mon Sep 17 00:00:00 2001 From: Ken Fallon Date: Mon, 20 Nov 2023 20:38:48 +0100 Subject: [PATCH] 2023-11-20_19-38-48Z_Monday --- bin/postshow.bash | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/bin/postshow.bash b/bin/postshow.bash index 90c8f10..b4def1b 100755 --- a/bin/postshow.bash +++ b/bin/postshow.bash @@ -155,17 +155,13 @@ fi # https://newbedev.com/how-to-urlencode-data-for-curl-command/ hostid="$( jq --raw-output '.host.Host_ID' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" host_name="$( jq --raw-output '.host.Host_Name' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" -#TODO title=$( grep -P "Title:\t" ${shownotes_txt} | awk -F "\t" '{print $2}' | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' ) -title=$( jq --raw-output '.episode.Title' ${shownotes_json} ) -#TODO summary="$( grep -P "Summary:\t" ${shownotes_txt} | awk -F "\t" '{print $2}' | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" -summary="$( jq --raw-output '.episode.Summary' ${shownotes_json} )" -#TODO jq --raw-output '.episode.Show_Notes' ${shownotes_json} -series="$( jq --raw-output '.episode.Series' ${shownotes_json} )" +title=$( jq --raw-output '.episode.Title' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' ) +summary="$( jq --raw-output '.episode.Summary' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" +series="$( jq --raw-output '.episode.Series' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" series_name="$( jq --raw-output '.episode.Series_Name' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" -explicit="$( jq --raw-output '.episode.Explicit' ${shownotes_json} )" -episode_license="$( jq --raw-output '.episode.Show_License' ${shownotes_json} )" -#TODO tags="$( grep -P "Tags:\t" ${shownotes_txt} | awk -F "\t" '{print $2}' | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" -tags="$( jq --raw-output '.episode.Tags' ${shownotes_json} )" +explicit="$( jq --raw-output '.episode.Explicit' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" +episode_license="$( jq --raw-output '.episode.Show_License' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" +tags="$( jq --raw-output '.episode.Tags' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )" host_license=$( jq --raw-output '.host.Host_License' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' ) host_profile=$( jq --raw-output '.host.Host_Profile' ${shownotes_json} | jq --slurp --raw-input @uri | sed -e 's/%0A"$//g' -e 's/^"//g' )