Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ghostty album cover image #660

Open
5183nischal opened this issue Jan 13, 2025 · 13 comments
Open

Ghostty album cover image #660

5183nischal opened this issue Jan 13, 2025 · 13 comments
Labels
enhancement New feature or request

Comments

@5183nischal
Copy link

Is your feature already implemented in the latest master?
No

Is your feature request related to a problem? Please describe.
Ghostty terminal supports kitty graphics but the album cover is not rendered using it.

Describe the solution you'd like
Use kitty graphics protocol to display album cover.

@5183nischal 5183nischal added the enhancement New feature or request label Jan 13, 2025
@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

It is rendered for me using ghostty on x86 Linux with Wayland.. are you maybe using a multiplexer like tmux? That could interfere with spotify_player being able to detect the terminal

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Try running spotify_player (built with the image feature ofc) using ghostty -e spotify_player and see if it works now :)

@5183nischal
Copy link
Author

Hi, thank you! Yes, tmux was the issue. Is there a way to get a proper rendering inside tmux? I didn't see anything in the docs.

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Hmm, not sure if this is an issue with this project, tmux or ghostty. Do you know if it works with tmux in kitty terminal? If so, that indicates that it should be solved in ghostty or tmux.

However, some other apps like yazi work for me in tmux with ghostty so maybe this can be fixed in here directly.

Unfortunately, I have no experience whatsoever with the kitty protocol and have no idea how to check if it is available.
However, right now I am digging through the codebase a bit so if I find a solution, I'll post it here

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Seems to be handled by https://github.com/atanunq/viuer

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Maybe relevant: atanunq/viuer#67

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

They check for "ghostty" in the "$TERM" environment variable. Maybe set it manually for now?

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Okay, when I do export TERM="xterm-ghostty", spotify_player won't start..

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Same for doing it through tmux and updating "TERM_PROGRAM"

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

I wonder how yazi (and image.nvim) do it...? I have

set -g allow-passthrough all
set -ga update-environment TERM
set -ga update-environment TERM_PROGRAM

in my tmux config but not quite sure what it does tbh

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Just commented out these lines and yazi kitty still works lol

@m4r1vs
Copy link
Contributor

m4r1vs commented Jan 16, 2025

Seems like this needs to be addressed in viuer because when we set the terminal to "xterm-ghostty" within tmux, viuer::get_kitty_support() blocks till infinity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants