Skip to content

Conversation

dgl
Copy link

@dgl dgl commented Dec 30, 2024

Adds support for Ghostty which only supports OSC 7 for proxy icon.

Copy link
Author

@dgl dgl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also opened ghostty-org/ghostty#3987 as there's some issues with the approach Ghostty makes of combining the document and pwd.

@mernen
Copy link
Owner

mernen commented Jan 2, 2025

Ghostty v1.0.1 is out with your patch. However, due to the issues you discussed in ghostty-org/ghostty#3987, I'm not sure the terminal is in a good state for this — I'm particularly bothered by how quitting vim just kills the proxy icon for the tab, and I don't think it should be this plugin's responsibility to attempt to restore it to the previous state, as it might not even match vim's cwd. I'm thinking of holding this a bit to see if they'll support OSC 6.

@dgl
Copy link
Author

dgl commented Jan 2, 2025

Fair enough, no need to merge, I've think we've discovered interesting things either way.

I'm particularly bothered by how quitting vim just kills the proxy icon for the tab

With the zsh shell integration I get the proxy icon back straight away, even if this clears it.

The bigger issue for me is opening a new tab ends up in /. I just realised I can hack around that as I don't usually want a PWD of /, so:

autocmd BufWinEnter,FocusGained * call system("pwd > ~/.vim-last-pwd")

(zshrc)

if [[ $PWD = / ]]; then
  cd "$(<~/.vim-last-pwd)"
fi

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

Successfully merging this pull request may close these issues.

2 participants