mirror of
https://github.com/m-housh/dotfiles.git
synced 2026-02-14 06:12:34 +00:00
Added go.nvim, updated ts script to accept a session argument
This commit is contained in:
@@ -8,23 +8,25 @@
|
||||
"cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" },
|
||||
"cmp-spell": { "branch": "master", "commit": "32a0867efa59b43edbb2db67b0871cfad90c9b66" },
|
||||
"formatter.nvim": { "branch": "master", "commit": "34dcdfa0c75df667743b2a50dd99c84a557376f0" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6a2c47e6424a3f1e373bfeb714b716f6be13501c" },
|
||||
"go.nvim": { "branch": "master", "commit": "2f573a297bea3a483a3607ae7c607a8a08d27993" },
|
||||
"guihua.lua": { "branch": "master", "commit": "5ad8dba19ce9b9fd8965598984dfdc9c119f97e4" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "59335c5b9d116f5d3948f833288a89e2a829a005" },
|
||||
"lazygit.nvim": { "branch": "main", "commit": "de35012036d43bca03628d40d083f7c02a4cda3f" },
|
||||
"lsp_signature.nvim": { "branch": "master", "commit": "bdf3dc7bb03edd25c2173e0e31c2fb122052ed23" },
|
||||
"lspkind-nvim": { "branch": "master", "commit": "57610d5ab560c073c465d6faf0c19f200cb67e6e" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "45e27ca739c7be6c49e5496d14fcf45a303c3a63" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "81e30dd629de24cbb26d08073ee938ab40006695" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "48025d62f45af52ba47e4193b854864839392e4c" },
|
||||
"mason.nvim": { "branch": "main", "commit": "d66c60e17dd6fd8165194b1d14d21f7eb2c1697a" },
|
||||
"neo-tree.nvim": { "branch": "v3.x", "commit": "71f1841ba6c652908678cece623f52c1fea8a6cd" },
|
||||
"neodev.nvim": { "branch": "main", "commit": "58b1c0740e8ad79ce71e2649a449bb90536435cf" },
|
||||
"neodev.nvim": { "branch": "main", "commit": "41581561a0ffc6ea6a191ee90a23f8c1c7f470fb" },
|
||||
"nightfox.nvim": { "branch": "main", "commit": "fe2fc7b93d66349eff2c5baa6cec922ee3958f56" },
|
||||
"noice.nvim": { "branch": "main", "commit": "396f9146529130904e07c45e90ecdbfa607534f3" },
|
||||
"nui.nvim": { "branch": "main", "commit": "c8de23342caf8d50b15d6b28368d36a56a69d76f" },
|
||||
"nvim-cmp": { "branch": "main", "commit": "5dce1b778b85c717f6614e3f4da45e9f19f54435" },
|
||||
"nvim-lsp-installer": { "branch": "main", "commit": "17e0bfa5f2c8854d1636fcd036dc8284db136baa" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "576c8a5987bb276d234dd1d04e6c9fe60da1185d" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "fabd2578cbce0a76d48afa4b369f27a08f03ead3" },
|
||||
"nvim-notify": { "branch": "master", "commit": "e4a2022f4fec2d5ebc79afa612f96d8b11c627b3" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "16ea2969ea0a5ba902fceece9b2db10c7c9ba2d6" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "776e4d341b5416c995e74c3abbf75f9cec26aa5e" },
|
||||
"nvim-treesitter-textobjects": { "branch": "master", "commit": "bd103502252027434ec42f628d2dbf54821d4ce6" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "45d0237c427baba8cd05e0ab26d30e2ee58c2c82" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "9ce85b0f7dcfe5358c0be937ad23e456907d410b" },
|
||||
|
||||
@@ -34,3 +34,14 @@ vim.api.nvim_create_autocmd(
|
||||
}
|
||||
)
|
||||
|
||||
vim.api.nvim_create_autocmd(
|
||||
"BufWritePre",
|
||||
{
|
||||
pattern = "*.go",
|
||||
callback = function()
|
||||
require('go.format').goimport()
|
||||
end,
|
||||
group = vim.api.nvim_create_augroup("GoFormat", { clear = true })
|
||||
}
|
||||
)
|
||||
|
||||
|
||||
@@ -34,6 +34,8 @@ keymap("n", "<c-n>", "<CMD>:Neotree toggle<CR>", default_options)
|
||||
|
||||
-- Toggle Lazy Git
|
||||
keymap("n", '<leader>gg', ':LazyGit<CR>', default_options)
|
||||
keymap("n", "<leader>gf", ":Telescope git_files<CR>", default_options)
|
||||
keymap("n", "<leader>t", ":ToggleTerm<CR>", default_options)
|
||||
|
||||
-- Toggle term key maps, that get attached when terminal is opened.
|
||||
function _G.set_terminal_keymaps()
|
||||
|
||||
@@ -95,10 +95,10 @@ return {
|
||||
["<C-d>"] = cmp.mapping.scroll_docs(-4),
|
||||
["<C-f>"] = cmp.mapping.scroll_docs(4),
|
||||
["<C-Space>"] = cmp.mapping.complete(),
|
||||
["<C-e>"] = cmp.mapping.close(),
|
||||
["<C-e>"] = cmp.mapping.abort(),
|
||||
["<CR>"] = cmp.mapping.confirm {
|
||||
behavior = cmp.ConfirmBehavior.Replace,
|
||||
select = false
|
||||
select = true
|
||||
},
|
||||
["<Tab>"] = cmp.mapping(function(fallback)
|
||||
if cmp.visible() then
|
||||
|
||||
15
nvim/m-housh/lua/user/plugin/go.lua
Normal file
15
nvim/m-housh/lua/user/plugin/go.lua
Normal file
@@ -0,0 +1,15 @@
|
||||
return {
|
||||
"ray-x/go.nvim",
|
||||
lazy = true,
|
||||
dependencies = { -- optional packages
|
||||
"ray-x/guihua.lua",
|
||||
"neovim/nvim-lspconfig",
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
},
|
||||
config = function()
|
||||
require("go").setup()
|
||||
end,
|
||||
event = {"CmdlineEnter"},
|
||||
ft = {"go", 'gomod'},
|
||||
build = ':lua require("go.install").update_all_sync()' -- if you need to install/update all binaries
|
||||
}
|
||||
@@ -14,7 +14,8 @@ return {
|
||||
"ray-x/lsp_signature.nvim",
|
||||
"neovim/nvim-lspconfig",
|
||||
"folke/neodev.nvim",
|
||||
"mhartington/formatter.nvim"
|
||||
"mhartington/formatter.nvim",
|
||||
"ray-x/go.nvim",
|
||||
},
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
|
||||
@@ -33,6 +33,7 @@ require("lazy").setup({
|
||||
{ import = 'user.plugin.lualine' },
|
||||
{ import = 'user.plugin.treesitter' },
|
||||
{ import = 'user.plugin.formatter' },
|
||||
{ import = 'user.plugin.go' },
|
||||
|
||||
-- Navigation --
|
||||
{ import = 'user.plugin.neo-tree' },
|
||||
|
||||
Reference in New Issue
Block a user