aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/uri.lua
Commit message (Collapse)AuthorAge
* fix: resolve all remaining LuaLS diagnosticsLewis Russell2025-01-27
|
* fix(uri): uri_encode encodes brackets incorrectly for RFC2732 #31284Jonny Kong2024-12-11
| | | | | | | | | | **Problem:** The brackets in the RFC2732 regular expression are currently unescaped, causing them to be misinterpreted as special characters denoting character groups rather than as literal characters. **Solution:** Escape the brackets. Fix #31270
* fix(lua): remove uri fragment from file paths (#27647)Ilia Choly2024-02-28
| | | | | | | Problem: Some LSP servers return `textDocument/documentLink` responses containing file URIs with line/column numbers in the fragment. `vim.uri_to_fname` returns invalid file names for these URIs. Solution: Remove the URI fragment from file URIs.
* feat(docs): replace lua2dox.luaLewis Russell2024-02-27
| | | | | | | | | | | | | | | | | | | | | | | | | | Problem: The documentation flow (`gen_vimdoc.py`) has several issues: - it's not very versatile - depends on doxygen - doesn't work well with Lua code as it requires an awkward filter script to convert it into pseudo-C. - The intermediate XML files and filters makes it too much like a rube goldberg machine. Solution: Re-implement the flow using Lua, LPEG and treesitter. - `gen_vimdoc.py` is now replaced with `gen_vimdoc.lua` and replicates a portion of the logic. - `lua2dox.lua` is gone! - No more XML files. - Doxygen is now longer used and instead we now use: - LPEG for comment parsing (see `scripts/luacats_grammar.lua` and `scripts/cdoc_grammar.lua`). - LPEG for C parsing (see `scripts/cdoc_parser.lua`) - Lua patterns for Lua parsing (see `scripts/luacats_parser.lua`). - Treesitter for Markdown parsing (see `scripts/text_utils.lua`). - The generated `runtime/doc/*.mpack` files have been removed. - `scripts/gen_eval_files.lua` now instead uses `scripts/cdoc_parser.lua` directly. - Text wrapping is implemented in `scripts/text_utils.lua` and appears to produce more consistent results (the main contributer to the diff of this change).
* docs: small fixes (#27213)dundargoc2024-02-06
| | | Co-authored-by: Matthieu Coudron <886074+teto@users.noreply.github.com>
* docs: fix type warningsMaria José Solano2023-09-23
|
* fix(loader): cache path ambiguity #24491Tyler Miller2023-08-01
| | | | | | | | | | | Problem: cache paths are derived by replacing each reserved/filesystem- path-sensitive char with a `%` char in the original path. With this method, two different files at two different paths (each containing `%` chars) can erroneously resolve to the very same cache path in certain edge-cases. Solution: derive cache paths by url-encoding the original (path) instead using `vim.uri_encode()` with `"rfc2396"`. Increment `Loader.VERSION` to denote this change.
* docs(lua): more improvements (#24387)Lewis Russell2023-07-18
| | | | | | | | | | | | | | | | | * docs(lua): teach lua2dox how to table * docs(lua): teach gen_vimdoc.py about local functions No more need to mark local functions with @private * docs(lua): mention @nodoc and @meta in dev-lua-doc * fixup! Co-authored-by: Justin M. Keyes <justinkz@gmail.com> --------- Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
* fix(lint): lint warnings #24226Raphael2023-07-10
|
* refactor: remove modelines from Lua filesGregory Anders2023-04-13
| | | | Now that we have builtin EditorConfig support and a formatting check in CI, these are not necessary.
* docs(uri): number → integer (#22515)Jaehwang Jung2023-03-04
|
* chore: format runtime with styluaChristian Clason2022-05-09
|
* fix(uri): change scheme pattern to not include the comma character (#16797)Dmytro Meleshko2021-12-26
|
* fix(uri): use valid EmmyLua annotations (#16359)Mathias Fußenegger2021-11-18
| | | | | | See: - https://emmylua.github.io/annotations/param.html - https://emmylua.github.io/annotations/return.html
* fix: correctly capture uri scheme on windows (#16027)Michael Lingelbach2021-10-15
| | | | | | closes https://github.com/neovim/neovim/issues/15261 * normalize uri path to forward slashes on windows * use a capture group on windows that avoids mistaking drive letters as uri scheme
* docs: make Lua docstrings consistent #15255Gregory Anders2021-08-22
| | | | | | | | | | | | The official developer documentation in in :h dev-lua-doc specifies to use "--@" for special/magic tokens. However, this format is not consistent with EmmyLua notation (used by some Lua language servers) nor with the C version of the magic docstring tokens which use three comment characters. Further, the code base is currently split between usage of "--@", "---@", and "--- @". In an effort to remain consistent, change all Lua magic tokens to use "---@" and update the developer documentation accordingly.
* feat(vim.uri): Allow URI schemes other than file: without authorityTom Payne2021-07-10
|
* fix(lsp): accept file URIs without a hostnameAlessandro Pezzoni2021-07-10
| | | | | | | RFC 8089, which defines the file URI scheme, also allows URIs without a hostname, i.e. of the form file:/path/to/file. These are returned by some language servers and accepted by other LSP implementations, such as VSCode's, so it is reasonable for us to accept them as well.
* doc: Add docs for uri functions (#12887)TJ DeVries2020-09-14
|
* Change uri_to_fname to not convert non-file URIs (#12351)Mathias Fußenegger2020-05-22
| | | | | | | | | * Change uri_to_fname to not convert non-file URIs A URI with a scheme other than file doesn't have a local file path. * fixup! Change uri_to_fname to not convert non-file URIs * fixup! fixup! Change uri_to_fname to not convert non-file URIs
* LSP: Avoid URI-to-fname conversion for non-file URIs #12243Mathias Fußenegger2020-05-04
| | | Fixes https://github.com/neovim/neovim/issues/12210
* vim.uri: fix uri_to_fname (#12059)Hirokazu Hata2020-03-30
| | | | | fix: #12056 If the colon of the drive letter of windows is URI encoded, it doesn't match the expected pattern, so decode it first.
* Add vim.uri_to_bufnrAshkan Kiani2019-11-20
|
* lua LSP client: initial implementation (#11336)Ashkan Kiani2019-11-13
Mainly configuration and RPC infrastructure can be considered "done". Specific requests and their callbacks will be improved later (and also served by plugins). There are also some TODO:s for the client itself, like incremental updates. Co-authored by at-tjdevries and at-h-michael, with many review/suggestion contributions.