In reference to question youtube-dl; How download ONLY the playlist, NOT the files therein
Can i get output like the following :
https://youtu.be/0gvUCLL-UGE | video title https://youtu.be/CPV7zcUy4J0 | video title https://youtu.be/4wyZNwIrH9I | video title
Example :
https://youtu.be/aYLBLOQrcAE | 5 More Amazing Kitchen Gadgets
The solution provided by @radiolondra works great,
youtube-dl -j --flat-playlist "https://" | jq -r '.id' | sed 's_^_https://youtu.be/_' > result.log
But, I am not able to figure out "JQ" command / query for my requirement.
Please Assist!
------------------Edited------------------
I tried jq -r ".id \ "+" .title" the output was
https://youtu.be/0gvUCLL-UGEvideo title
was not able to insert " | " in between [id] and [title] Others that ended with error:
jq -r "map([.id, .title] | join("| ")) | join('\n')"
jq -r "map([.id, .title] | join(", ")) | join('\n')"
jq -r "map([.id, .title] | join(', ')) | join('\n')"
jq -r "map([.id, .title] | join('| ')) | join('\n')"
jq -r "map([.id, .title] | join(" ")) | join('\n')"
jq -r "map([.id, .title] | join(' ')) | join('\n')"
-----------------------Edited-----------------------
Following modifications seems to be working in Linux, but not able to make them work on windows :
jq -r '.entries | map(.id +" | "+ .title) | join("\n")'
jq -r '.[] | map(.id +" | "+ .title) | join("\n")'
On windows i keep getting the following error:
jq: error: syntax error, unexpected INVALID_CHARACTER, expecting $end (Windows cmd shell quoting issues?) at , line 1: '.entries jq: 1 compile error 'map' is not recognized as an internal or external command, operable program or batch file.