Lauraaaaaaaa ask before commiting to master
This commit is contained in:
commit
2fd9175a79
|
@ -77,6 +77,20 @@ if [[ "${get_data[v]}" ]]; then
|
||||||
strings[title]=$(jq -r '.title' <<< "$video")
|
strings[title]=$(jq -r '.title' <<< "$video")
|
||||||
if [[ ${cfg[template]} == 'default' ]]; then
|
if [[ ${cfg[template]} == 'default' ]]; then
|
||||||
meta[title]="${strings[title]}"
|
meta[title]="${strings[title]}"
|
||||||
|
meta[description]="$(jq -r '.description' <<< "$video")"
|
||||||
|
meta[unsafe]="
|
||||||
|
<meta property='og:image' content='$(jq -r '.thumbnails[-1].url' <<< "$video")'>
|
||||||
|
<meta property='og:type' content='video.other'>
|
||||||
|
<meta property='video:duration' content='$(jq -r '.duration' <<< "$video")'>
|
||||||
|
"'<script type="application/ld+json">'"$(jq '{
|
||||||
|
"@context": "https://schema.org",
|
||||||
|
"@type": "VideoObject",
|
||||||
|
"name": .title,
|
||||||
|
"alternateName": .alt_title,
|
||||||
|
"description": .description,
|
||||||
|
"thumbnail": .thumbnails[-1].url,
|
||||||
|
"duration": ("PT" + (.duration | tostring) + "S"),
|
||||||
|
}' <<< "$video")"'</script>'
|
||||||
source templates/head.sh
|
source templates/head.sh
|
||||||
fi
|
fi
|
||||||
formats=$(jq '.formats' <<< "$video")
|
formats=$(jq '.formats' <<< "$video")
|
||||||
|
|
Loading…
Reference in a new issue