Files
macvim-mirror/runtime
Yee Cheng Chin 653366fb23 Fix mvim:// protocol double-encoding behavior handling properly
Change mvim:// protocol behavior back to previous state to double-encode
the file path, since we are encapsulating a file:// protocol (which has
encoded path) within another URL as a query, which itself should be
encoded. This means a file path "/tmp/file name.txt" should be properly
encoded as mvim://open?url=file:///tmp/file%2520name.txt, as the space
is encoded twice (first to %20, then to %2520).

Previously we tried to fix the protocol handler to only do a single
encoding (see #1021 and #1043) but it's really an incorrect usage of
URL. The reason for that fix was that tools like iTerm2 was passing in
single-encoded URLs. As such, also add a compatibility feature here
where we will optimiscally try to re-encode characters that we detect to
be erroneously encoded. For example, if we see
mvim://open?url=file:///tmp/file%20name.txt, MacVim will intelligently
realize that the space needs to be encoded again. The only character
where that won't work is the "%" character because of the ambiguity
involved, so a file path "/tmp/file%.txt" will only work with this:
mvim://open?url=file:///tmp/file%2525.txt

Close #1020 (also see the issue for discussions).
2020-07-05 23:30:44 -07:00
..
2020-04-10 22:10:56 +02:00
2020-05-26 21:20:45 +02:00
2020-06-21 22:12:03 +02:00
2020-05-26 21:20:45 +02:00
2020-06-14 17:29:55 +02:00
2020-06-21 22:12:03 +02:00
2020-06-07 21:07:18 +02:00
2020-06-14 17:29:55 +02:00
2020-04-10 22:10:56 +02:00