-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
Man writer fails to handle links with non-ASCII characters. #8508
Comments
Pandoc's man writer will simply skip relative links, because they are generally just clutter in a man page. |
You are right, it is not. However, the philosophy of Markdown is
— https://daringfireball.net/projects/markdown/syntax#philosophy Escaping special characters in URI makes it hardly-to-read and hardly-to-write. Just compare:
or:
I believe Markdown processor (pandoc) should allow most of characters to be unescaped, and take care about escaping and de-escaping them behind the scene, if required. For example, Mozilla Firefox browser allows entering invalid URI ( For sake of writability and readability, pandoc should allow all of the characters to be unescaped, with very few exceptions:
Probably, I forgot something else, like new-line character. Probably, pandoc should not worry about escaping at all, since Firefox, Chromium, and Epiphany browsers handle such links properly:
and I guess all other modern browsers do that, too. |
Yes, I agree that we should handle these unescaped characters in URIs -- I was just explaining why pandoc currently behaves the way it does. It shouldn't be too complicated to fix this -- maybe just URI escape non-ascii characters before calling isURI. |
Example:
Note the second link, EBNF: it contains non-ASCII character, en-dash, between "Backus" and "Naur".
HTML writer uses both link targets as-is. It is ok, since most browsers (at least, Firefox and Chromium) handle it correctly.
However, let's see how they are handled by man writer:
The first link is written correctly, but the second link just disappeared.
Pandoc version:
The text was updated successfully, but these errors were encountered: