slavistan / lf-gadgets

A collection of useful and nifty use cases and configurations for lf.
GNU General Public License v3.0
132 stars 16 forks source link

Issue with lf-yt #1

Closed MuizU closed 3 years ago

MuizU commented 3 years ago

jq: error (at <stdin>:15): Cannot iterate over null (null) jq: error (at <stdin>:15): Cannot iterate over null (null) jq: error (at <stdin>:15): Cannot iterate over null (null) curl: option -o: requires parameter curl: try 'curl --help' for more information I keep on getting this error despite everything being there

slavistan commented 3 years ago

Hi, apologies for the late reply.

May I kindly ask you to update lf as the last week has seen new major releases which incorporate changes necessary for lf-yt to work (a few days ago you would have had to install lf from source, something which I did not explicitly mention in the readme). Also, check jq --version, which should be ≥ 1.6.

MuizU commented 3 years ago

I have the latest release for lf and my jq --version is 1.6 but I still get the error image

slavistan commented 3 years ago

Alright, let's check your API-key. Kindly run this in your shell and report your output.

query=chopin
maxresults=2
YT_API_KEY="..." # your api key here

curl -s "https://www.googleapis.com/youtube/v3/search?part=snippet&q=$query&type=video&maxResults=$maxresults&key=$YT_API_KEY"

Btw, which search query did you run that gave you the error?

MuizU commented 3 years ago

It was an API key issue. Thanks for the help