RaitaroH / adl

🍿 anime scraper/downloader + trackma wrapper
GNU General Public License v3.0
140 stars 15 forks source link

adl not showing the covers in the fish shell #40

Closed zenmaster3000 closed 2 years ago

zenmaster3000 commented 2 years ago

It seems that the way it execute escapes the bash shell environment of the script, so the preview will not work. To fix this, the SHELL variable needs to be set at the beginning:

readonly BASH_BINARY="$(which bash)" SHELL="${BASH_BINARY}"

RaitaroH commented 2 years ago

Can you provide a PR for this? On my end, the covers don't work in fish, without or with your code.

This might be an upstream problem though. What is your fish/bash version?

fish, version 3.1.0
GNU bash, version 5.0.17(1)-release
zenmaster3000 commented 2 years ago

You have to set it at the very beginning of the script. Since I was missing some updates from the git I decided to better create an alias in fish:

SHELL=/usr/bin/bash /home/<username>/.local/bin/adl -c

Of course change to the username in your pc.

Here are my versions:

fish, version 3.5.1
ueberzug 18.1.9
GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)

Try getting ueberzug working by itself first: I have uploaded my test script here. It is modified to work with fish since the original needed the fixes discussed here, so it should work for you.

RaitaroH commented 2 years ago

It is possible one of my shells is too old, but if it works for you that is good. The alias fix should suffice I think. I am not sure how adding the shell would affect the script on Windows.

zenmaster3000 commented 2 years ago

That might be but I wonder if ueberzug works on Windows.

RaitaroH commented 2 years ago

I am simply worried for the rest of the script having issues on Windows.