Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Forward the download location to another (grep) program? #26515
Comments
|
Just get it from the youtube-dl output? |
|
Can you explain more? I have read youtube-dl manual and dont find anything about how to get it there. |
|
You want to get the value of |
|
Yes, and get that to grep. Specially the json file. As said before, I already have $folder so only youtube-dl value of |
|
Youtube-dl prints complete name of a file
You could extract that by grepping its output. You could also use |
|
Thanks for your help. Have completely missed that part that youtube-dl prints the name and path of the video file. Have just got information about a program called xidel and with that no need to download description or json file. I do not know how to do this but some how get the path and filename of from youtube-dl, replace the extension (mp4) with txt and dump the xidel output there to that text file. I do not want to run youtube-dl two times. youtube-dl output
txt file for xidel to dump the output from the script below.
|
|
At this point it's not a youtube-dl issue, you need to learn bash basics. |
Checklist
Question
WRITE QUESTION HERE
Trying to make a easy to use script to download YouTube videos easy and also create a info file with Title, Channel, channel URL, upload date, tags, url to video and also description. I found that the information is in the JSON file that youtube-dl download. What Im struggling with is how to get the folder location information from youtube-dl to grep that then can access JSON file and copy that information to a dedicated text file.
$folder'/%(title)s/%(title)s - (%(id)s) - %(uploader)s - %(upload_date)s.%(ext)s'
$folder is a location the user choose earlier in the script. I have added ID, uploader and upload date to the files because that is the only way I know to get that information saved in a "easy" way to access it.
Is there a way to do this?
More information about the script here https://stackoverflow.com/questions/63336809/youtube-dl-download-script-debug