---

Title: YouTube Search or How I found Googler

Published: 2021-03-29 15:10

Author: Rev. Fr. Robert Bower

Tag:

layout: blog

---

YouTube Search or How I found Googler

There have been many blog posts and videos about how to view YouTube videos from the command line. But what if you want to search for YouTube videos from the command line. The only dedicated utility I know is MPS-youtube.

https://github.com/mps-youtube/mps-youtube

You may find it fits your needs. I always had trouble with it. I think most of the issues were probably me.

I have been using YouTube-dl to download videos for many years and using mpv to stream and watch YouTube videos. I was always looking for a search component. Today I found it. I came across two utilities, googler and ddgr. Googler is a utility that lets you search Google from the command line and ddgr lets you search Duck Duck Go from the command line.

https://github.com/jarun/googler

https://github.com/jarun/ddgr

I downloaded googler since I wanted to search for YouTube videos. Google is not my search engine of choice but it does make sense to search a Google site with Google.

Now, with a one line script I can search for videos and watch videos from the command line.

The -w option tells googler to only search YouTube and the --url-handler option tells it to pass the selected search result to mpv. $@ tells googler to use what ever I type for arguments use as the search parameters.

Zettelkasten ID **googler-2021-03-29-1510**

Proxied content from gemini://frrobert.net/log/googler-2021-03-29-1510.gmi

Gemini request details:

Original URL
gemini://frrobert.net/log/googler-2021-03-29-1510.gmi
Status code
Success
Meta
text/gemini
Proxied by
kineto

Be advised that no attempt was made to verify the remote SSL certificate.