Compare commits

...

2 Commits

Author SHA1 Message Date
Sam W 2231683ffc vim: add html5 plugin, update nixpkgs 2022-12-27 01:23:32 +00:00
Sam W 9017475528 vim: Add rustopendocs command 2022-12-16 21:14:20 +00:00
4 changed files with 20 additions and 5 deletions

View File

@ -62,16 +62,16 @@
},
"nixpkgs": {
"locked": {
"lastModified": 1671040593,
"narHash": "sha256-W5aZNwYBjaEaLifDWGEfecvnCiDkXjI26rHgidSftUM=",
"lastModified": 1672102598,
"narHash": "sha256-7fzlPrDEpej/8ORSk7V4H4W6koOMD0juQ/M7whewNpk=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "170e39462b516bd1475ce9184f7bb93106d27c59",
"rev": "93c0d5dcf02409fe705500e90af38b33d3a259d3",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-22.11",
"ref": "release-22.11",
"repo": "nixpkgs",
"type": "github"
}

View File

@ -2,7 +2,7 @@
description = "Samw's home environment, as managed by nix/home-manager.";
inputs = {
# Nixpkgs
nixpkgs = {url = "github:nixos/nixpkgs/nixos-22.11";};
nixpkgs = {url = "github:nixos/nixpkgs/release-22.11";};
# Other modules
home-manager = {
url = "github:nix-community/home-manager/release-22.11";

View File

@ -32,6 +32,7 @@ in {
dhall-vim
kotlin-vim
Jenkinsfile-vim-syntax
html5-vim
]
# delve is unsupported on aarch64-linux and golangci-lint is broken on darwin
# (see https://github.com/NixOS/nixpkgs/issues/168984).

View File

@ -62,6 +62,20 @@ require'lspconfig'.rnix.setup{
require'lspconfig'.rust_analyzer.setup{
on_attach = on_attach,
capabilities = capabilities,
commands = {
RustOpenDocs = {
function()
vim.lsp.buf_request(vim.api.nvim_get_current_buf(), 'experimental/externalDocs', vim.lsp.util.make_position_params(), function(err, url)
if err then
error(tostring(err))
else
vim.fn['netrw#BrowseX'](url, 0)
end
end)
end,
description = 'Open documentation for the symbol under the cursor in default browser',
},
},
}
require'lspconfig'.dhall_lsp_server.setup{
on_attach = on_attach,