Parse YouTube online videos on Linux with quvi

In newly Post I made about youtube-dl I was left with a question, if when downloading a video with youtube-dl it puts the title of the video from YouTube to the file, how do you do it? How is it possible for applications to extract data from videos posted on online video or movie sites?

I imagine parsing the HTML code, which means that it reads all the HTML up to where it says "title" or something like that, and that text (the video title) is what gives the file its name. Well, it does (or at least I think so), but, here is my question, How to parse a page to get video data from the terminal?

what it is an excellent option to use!

Take for example the official video of Movistar Unboxing ZTE Open. but first we will install what:

Installation

In Debian, Ubuntu or derivatives, a:

sudo apt-get install quvi

In ArchLinux or derivatives:

sudo pacman -S quvi

Easier

Once installed, we go on to use it.

Taking as an example the URL of the video that I put above, we are going to extract its information:

quvi dump http://www.youtube.com/watch?v=Wjs3_hY29Q8

We will see all the information related to the video, for example, its title, URL, ID of the video on the site, duration in milliseconds, thumbnail, format ... etc:

quvi-dump

In ArchLinux there is the version of quvi 0.9.5-1 available, in other distros like Debian there is only version 0.4.2. When you use old versions and want to remove the information from the video, skip (don't put) the dump. They simply put quvi followed by the URL of the video

Also, using the command grep As you can see, we can filter the output and show only what we want 😉

Ah, also, if they do a man quvi-dump It will show you many options for this parameter, since it allows you to save that information in a json, xml, check subtitles, etc.

That's what the parameter does dump, shows us video information, but, What to use if i want to save the video on my computer?

To save it we use the parameter get, as simple as:

quvi get http://www.youtube.com/watch?v=Wjs3_hY29Q8

quvi-get

… Don't look at the download speed hehe.

In the latest versions of quvi you cannot do the following, but in versions like the one in Debian you can see the video directly without downloading it, you can see how in the Wiki of Arch. Yes, as you read, in the ArchLinux Wiki there is something wrong 😀

The end!

Well, this is all.

I really recommend that you read the help for each parameter, you will find a lot of information and interesting options.

regards

youtube-terminal


The content of the article adheres to our principles of editorial ethics. To report an error click here!.

9 comments, leave yours

Leave a Comment

Your email address will not be published. Required fields are marked with *

*

*

  1. Responsible for the data: Miguel Ángel Gatón
  2. Purpose of the data: Control SPAM, comment management.
  3. Legitimation: Your consent
  4. Communication of the data: The data will not be communicated to third parties except by legal obligation.
  5. Data storage: Database hosted by Occentus Networks (EU)
  6. Rights: At any time you can limit, recover and delete your information.

  1.   Yoyo said

    The first time I hear, or read, that of «parsing» O_0

    1.    KZKG ^ Gaara said

      Is that ... imagine compa Yoyo, you are light years from my perfect intelligence ... LOL !!

      Nothing serious anymore, "parse" as a verb does not exist, it is something that lazy people or lazy people like us invented so as not to have to say "parse and extract information"
      It has been something like this: https://groups.google.com/d/topic/phplatinoamerica/nBe6PQm-VVY

      That is related to PHP, but hey, that's where the shots go.

  2.   Ale said

    C: /> my eyesss aarggggg !!!

    1.    Atheyus said

      It is Linux only with the modified prompt 😛

      Good information thanks: D.

  3.   Brian said

    Very interesting, thanks and a question. What is only good for youtube?

    1.    KZKG ^ Gaara said

      In theory it should work for sites other than YouTube, but I did not test.
      Try it and tell us 😀

      1.    Brian said

        I tried some other page and there was no case. In some I could not test because I don't know how to get the address of the video that is in an integrated player.

  4.   Gregorio Espadas said

    I didn't know about it, I already know where I'm going to try it, hopefully it works. Thanks for the tip!

    1.    KZKG ^ Gaara said

      Thanks to you bro 😉