mirror of
https://github.com/neovim/neovim.git
synced 2025-09-07 11:58:17 +00:00
docs: fix typos (#23917)
This commit is contained in:

committed by
GitHub

parent
5959b3c922
commit
7154f0c986
@@ -2563,7 +2563,7 @@ set({mode}, {lhs}, {rhs}, {opts}) *vim.keymap.set()*
|
|||||||
-- Map to a Lua function:
|
-- Map to a Lua function:
|
||||||
vim.keymap.set('n', 'lhs', function() print("real lua function") end)
|
vim.keymap.set('n', 'lhs', function() print("real lua function") end)
|
||||||
-- Map to multiple modes:
|
-- Map to multiple modes:
|
||||||
vim.keymap.set({'n', 'v'}, '<leader>lr', vim.lsp.buf.references, { buffer=true })
|
vim.keymap.set({'n', 'v'}, '<leader>lr', vim.lsp.buf.references, { buffer = true })
|
||||||
-- Buffer-local mapping:
|
-- Buffer-local mapping:
|
||||||
vim.keymap.set('n', '<leader>w', "<cmd>w<cr>", { silent = true, buffer = 5 })
|
vim.keymap.set('n', '<leader>w', "<cmd>w<cr>", { silent = true, buffer = 5 })
|
||||||
-- Expr mapping:
|
-- Expr mapping:
|
||||||
@@ -2697,8 +2697,8 @@ find({names}, {opts}) *vim.fs.find()*
|
|||||||
directories
|
directories
|
||||||
|
|
||||||
joinpath({...}) *vim.fs.joinpath()*
|
joinpath({...}) *vim.fs.joinpath()*
|
||||||
Concatenate directories and/or file into a single path with normalization
|
Concatenate directories and/or file paths into a single path with
|
||||||
(e.g., `"foo/"` and `"bar"` get joined to `"foo/bar"`)
|
normalization (e.g., `"foo/"` and `"bar"` get joined to `"foo/bar"`)
|
||||||
|
|
||||||
Parameters: ~
|
Parameters: ~
|
||||||
• {...} (string)
|
• {...} (string)
|
||||||
|
@@ -72,7 +72,7 @@ function M.basename(file)
|
|||||||
return file:match('[/\\]$') and '' or (file:match('[^\\/]*$'):gsub('\\', '/'))
|
return file:match('[/\\]$') and '' or (file:match('[^\\/]*$'):gsub('\\', '/'))
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Concatenate directories and/or file into a single path with normalization
|
--- Concatenate directories and/or file paths into a single path with normalization
|
||||||
--- (e.g., `"foo/"` and `"bar"` get joined to `"foo/bar"`)
|
--- (e.g., `"foo/"` and `"bar"` get joined to `"foo/bar"`)
|
||||||
---
|
---
|
||||||
---@param ... string
|
---@param ... string
|
||||||
|
@@ -6,7 +6,7 @@ local keymap = {}
|
|||||||
--- -- Map to a Lua function:
|
--- -- Map to a Lua function:
|
||||||
--- vim.keymap.set('n', 'lhs', function() print("real lua function") end)
|
--- vim.keymap.set('n', 'lhs', function() print("real lua function") end)
|
||||||
--- -- Map to multiple modes:
|
--- -- Map to multiple modes:
|
||||||
--- vim.keymap.set({'n', 'v'}, '<leader>lr', vim.lsp.buf.references, { buffer=true })
|
--- vim.keymap.set({'n', 'v'}, '<leader>lr', vim.lsp.buf.references, { buffer = true })
|
||||||
--- -- Buffer-local mapping:
|
--- -- Buffer-local mapping:
|
||||||
--- vim.keymap.set('n', '<leader>w', "<cmd>w<cr>", { silent = true, buffer = 5 })
|
--- vim.keymap.set('n', '<leader>w', "<cmd>w<cr>", { silent = true, buffer = 5 })
|
||||||
--- -- Expr mapping:
|
--- -- Expr mapping:
|
||||||
|
Reference in New Issue
Block a user