João Távora writes: > I think it's better to patch eglot--uri-to-path so that if X looks > anything other than file://, Eglot leaves it untouched. After all, it's > the only safe translation Eglot can make. I've attached patch 0001-Only-handle-file-type-URIs-in-eglot-explicitly.patch to this email that does this pretty well > And in eglot--path-to-uri, we do likewise. If the PATH argument already > looks vaguely URIish (say, it makes something like "^[[:alnum:]]+://") > we leave it unchanged. This is done by just trying to parse the path as a URL and checking the url-type instead of checking a regex. > Felicián also suggested that Eglot warns the user when it doesn't know > an URI scheme. I think that can make sense in some situations, for now > let's assume it isn't as important as getting your new Jar > file-name-handler to integrate with Eglot. Maybe in some later patch > Eglot can somehow predict if there is a file-name-handler entry for a > given URI and only warn if there isn't. This change is only a matter of consulting the `find-file-name-handler` function. I added another patch for that as 0002-Warn-when-eglot-receives-a-non-file-type-URI-that-Em.patch