Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for printing the basic youtube URL #4445

Closed
HalosGhost opened this issue Dec 11, 2014 · 3 comments
Closed

Add support for printing the basic youtube URL #4445

HalosGhost opened this issue Dec 11, 2014 · 3 comments
Labels

Comments

@HalosGhost
Copy link

@HalosGhost HalosGhost commented Dec 11, 2014

Using the --get-url (or -g) option returns an incredibly long URL that adds significantly more data than is necessary. It would be nice to have an option that prints the standard "youtube.com/watch?v=$id". Any interest in adding this (I cannot imagine it would be too hard to add since it would essentially just be prepending the basic address to the standard output of --get-id)?

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Dec 11, 2014

--get-url returns the final downloadable URL for particular format exactly as returned by video hoster. What is the rationale for returning back the same URL you just passed in?

@HalosGhost
Copy link
Author

@HalosGhost HalosGhost commented Dec 11, 2014

Ahh, I wasn't clear about that was I. I meant specifically for the ytsearch extractor. In this case, I do not know the basic URL,

@dstftw dstftw added the request label Dec 11, 2014
@jaimeMF
Copy link
Collaborator

@jaimeMF jaimeMF commented Dec 11, 2014

You can use jq for that:

$ youtube-dl ytsearch2:python -j | jq .webpage_url
"https://www.youtube.com/watch?v=tKTZoB2Vjuk"
"https://www.youtube.com/watch?v=ohr6O78jGzs"
@phihag phihag closed this Dec 11, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.