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

Extra trailing > character in URL #86

Closed
wdscxsj opened this issue Apr 23, 2020 · 4 comments
Closed

Extra trailing > character in URL #86

wdscxsj opened this issue Apr 23, 2020 · 4 comments

Comments

@wdscxsj
Copy link

wdscxsj commented Apr 23, 2020

For example, the URL [https://certbot.eff.org/](https://certbot.eff.org/) is correctly rendered as:

1

But on mouse hover, an extra > character is appended to the URL:

2

And on click the browser tries to open https://certbot.eff.org/> and fails.

My environment: patat 0.8.4.3 64-bit on Ubuntu 18.04.

@jaspervdj
Copy link
Owner

Hi @wdscxsj, this is not really patat's doing. There is no way to output links in terminal output, so patat just outputs <https://certbot.eff.org/> and then the terminal emulator (e.g. gnome-terminal) highlights it and makes it clickable.

It is pretty common to use <> around URLs as this was part of the original markdown specification. However, if this breaks many terminal emulators, we can consider dropping these. Can you let us know which terminal emulator and/or highlighter you are using?

@wdscxsj
Copy link
Author

wdscxsj commented Apr 27, 2020

Thanks for the explanation! I never thought it was the terminal. The issue happened when I used VSCode's Remote feature to ssh into a Ubuntu 18.04 from Windows 10, and then run patat inside VSCode's (remote bash) terminal. No particular highlighter is configured other than a Light theme for VSCode.

A minimal example:

See [https://certbot.eff.org/](https://certbot.eff.org/) for example.

See [https://certbot.eff.org/](https://certbot.eff.org/).

On my laptop, the reported issue happens to the first line, but not to the second.

By the way, neither Windows cmd.exe nor ConEmu has this problem. Can we decide it's a bug of VSCode?

@jaspervdj
Copy link
Owner

Yes, I think it that case it would be a bug in the VSCode URL highlighter. You should also be able to reproduce this without patat by simply running:

echo '<https://certbot.eff.org/>'

@wdscxsj
Copy link
Author

wdscxsj commented Apr 28, 2020

You should also be able to reproduce this without patat by simply running:

echo '<https://certbot.eff.org/>'

Confirmed. Thank you very much! I can close this one now.

Update: This issue is tracked here.

@wdscxsj wdscxsj closed this as completed Apr 28, 2020
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

No branches or pull requests

2 participants