HomeinetWatch YouTube videos in Linux terminal using YTFZF

Watch YouTube videos in Linux terminal using YTFZF

If you are a Linux terminal enthusiast who wants to watch YouTube videos without opening a browser, then ytfzf is a command line utility that you might be interested in.

Watch YouTube videos in Linux terminal using YTFZF

ytfzf is simply a POSIX script that allows you to search, play, and download YouTube videos without leaving the terminal.

It is available for all Unix-like operating systems, including Linux and macOS. However, the thumbnail preview feature is not currently available on macOS.

More macOS news : macOS 11.3: Rosetta can be removed from M1 Macs

How to install YTFZF video downloader?

The easiest way to get ytfzf on any operating system is to first clone the repository and then install it with the Makefile.

Watch YouTube videos in Linux terminal using YTFZF
Linux

If you are using Arch Linux, then ytfzf is already available in the AUR repo, which you can install by running the command:

Watch YouTube videos in Linux terminal using YTFZF

After installing the utility, you also need to install some of the dependencies it uses:

  • mpv video player
  • youtube-dl for downloading videos
  • fzf for menu (optional)
  • jq for parsing JSON data
  • thumbnail overlay (optional)
Watch YouTube videos in Linux terminal using YTFZF

For Debian-based distributions, you need to install youtube-dl from its official repo, as Debian repos contain the old version.

Useful Guide to Linux: What are the best Linux distributions for 2021?

And if you want to search for videos with thumbnails, you also need to install the Ueberzug utility:

Watch YouTube videos in Linux terminal using YTFZF

Features of YTFZF video downloader

Once you have properly installed ytfzf, you can start searching for YouTube videos by running the command ytfzf or ytfzf :

Watch YouTube videos in Linux terminal using YTFZF

If you also want to see the thumbnail preview, you can use the -t flag as ytfzf -t<query> .

Linux

As you can see, it lists the top result in the right panel and the thumbnail preview of the current videos in the left panel.

Important update news: The Linux Mint team wants users to update anyway

You can select the video to play using the default MPV video player. Key binding for MPV player is also available, such as f for full screen, J for subtitles and L for single-loop.

Linux

If you want to close the video selection message, you can either press ESC or CTRL + C.

Besides, it also allows you to queue videos using fzf multi-select option. You can press tab to select a video and queue it in mpv.

Linux

Ytfzf is under continuous development. If you want to contribute or learn more about it, such as changing the configuration, take a look at the official repository.

Information source: fossbytes.com

📧
Subscribe to the SecNews Newsletter

The most important Security & Technology news in your Inbox.

Teo Ehc
Teo Ehchttps://www.secnews.gr
Be the limited edition.

SEARCH

FOLLOW US

📧
Newsletter SecNews
The most important Security & Technology news in your inbox.

LIVE NEWS