doc: fix scripts and regenerate (#12506)

* Fix some small doc issues

* doc: fixup

* doc: fixup

* Fix lint and rebase

* Remove bad advice

* Ugh, stupid mpack files...

* Don't let people include these for now until they specifically want to

* Prevent duplicate tag
This commit is contained in:
TJ DeVries
2020-07-02 07:09:17 -04:00
committed by GitHub
parent 2844cd54da
commit 7b529e7912
13 changed files with 474 additions and 156 deletions

View File

@@ -23,6 +23,9 @@ local function request(method, params, callback)
return vim.lsp.buf_request(0, method, params, callback)
end
--- Sends a notification through all clients associated with current buffer.
--
--@return `true` if server responds.
function M.server_ready()
return not not vim.lsp.buf_notify(0, "window/progress", {})
end
@@ -69,6 +72,10 @@ function M.formatting(options)
return request('textDocument/formatting', params)
end
--- Perform |vim.lsp.buf.formatting()| synchronously.
---
--- Useful for running on save, to make sure buffer is formatted prior to being
--- saved. {timeout_ms} is passed on to |vim.lsp.buf_request_sync()|.
function M.formatting_sync(options, timeout_ms)
local params = util.make_formatting_params(options)
local result = vim.lsp.buf_request_sync(0, "textDocument/formatting", params, timeout_ms)
@@ -136,6 +143,12 @@ function M.document_symbol()
request('textDocument/documentSymbol', params)
end
--- Lists all symbols in the current workspace in the quickfix window.
---
--- The list is filtered against the optional argument {query};
--- if the argument is omitted from the call, the user is prompted to enter a string on the command line.
--- An empty string means no filtering is done.
function M.workspace_symbol(query)
query = query or npcall(vfn.input, "Query: ")
local params = {query = query}