3rd / image.nvim

🖼️ Bringing images to Neovim.
MIT License
803 stars 35 forks source link

Ability to supply headers/modify the http request to fetch remote images #178

Open dlvhdr opened 3 weeks ago

dlvhdr commented 3 weeks ago

Hi, thanks for the plugin. I'm using octo.nvim to do code reviews and it presents the summary of the PR in neovim. I would like to view the images in neovim as well. These images are stored in a private github repo that I have access to, using my cookie/token. Would it be possible to supply these when this plugin fetches the images? Something like gh auth token will give me my github token that I can then supply this plugin with to fetch the remote images.

Thank you!

3rd commented 3 weeks ago

Hey, would it be enough to make the arguments we send to curl configurable so you can pass --header?

dlvhdr commented 3 weeks ago

So did more research and apparently github makes it really hard. They require both session cookie and a token. They then redirect to s3. Makes it very hard to just use gh auth token