diff --git a/lua/config/remap.lua b/lua/config/remap.lua index d5f9c6b..a62d4e1 100644 --- a/lua/config/remap.lua +++ b/lua/config/remap.lua @@ -40,6 +40,7 @@ vim.keymap.set("n", "a", ":lua vim.lsp.buf.code_action()") local builtin = require("telescope.builtin") vim.keymap.set("n", "ff", builtin.find_files, {}) +vim.keymap.set("n", "fp", "Telescope flutter commands", {}) vim.keymap.set("n", "fg", builtin.live_grep, {}) vim.keymap.set("n", "fb", builtin.buffers, {}) vim.keymap.set("n", "fh", builtin.help_tags, {}) @@ -59,3 +60,14 @@ vim.keymap.set("n", "d", ":lua vim.lsp.buf.hover()") -- Clear highlighting on escape in normal mode vim.keymap.set("n", "", ":noh") vim.keymap.set("n", "^[", "^[") + +-- Easier shortcuts to move the cursor to the end or start of a line +vim.keymap.set("n", "", "", { noremap = true }) +vim.keymap.set("i", "", "", { noremap = true }) +vim.keymap.set("n", "", "", { noremap = true }) +vim.keymap.set("i", "", "", { noremap = true }) +-- Easier move cursor in insert mode +vim.keymap.set("i", "", "", { noremap = true }) +vim.keymap.set("i", "", "", { noremap = true }) +vim.keymap.set("i", "", "", { noremap = true }) +vim.keymap.set("i", "", "", { noremap = true }) diff --git a/lua/main/init.lua b/lua/main/init.lua index d8ba7cc..6d18225 100644 --- a/lua/main/init.lua +++ b/lua/main/init.lua @@ -7,7 +7,7 @@ vim.opt["shiftwidth"] = 4 vim.wo.relativenumber = true -require("oil").setup() +--require("oil").setup() -- If you want to see more details: --require("oil").set_columns({ "icon", "permission", "size" }) @@ -21,6 +21,9 @@ require("conform").setup({ }, }) +-- flutter telescope integration +require("telescope").load_extension("flutter") + vim.api.nvim_create_autocmd("BufWritePre", { pattern = "*", callback = function(args) @@ -36,3 +39,6 @@ require("flutter-tools").setup({ open_cmd = "tabedit", }, }) + +-- activate exrc to allow to run per project custom configs from .nvim.lua +vim.opt.exrc = true diff --git a/lua/plugins/prettier.lua b/lua/plugins/prettier.lua index 4d6633f..b5cc892 100644 --- a/lua/plugins/prettier.lua +++ b/lua/plugins/prettier.lua @@ -7,4 +7,11 @@ return { "m4xshen/autoclose.nvim", opts = {}, }, + { + "numToStr/Comment.nvim", + opts = {}, + config = function() + require("Comment").setup() + end, + }, } diff --git a/lua/plugins/ui.lua b/lua/plugins/ui.lua index c0a7e07..158767c 100644 --- a/lua/plugins/ui.lua +++ b/lua/plugins/ui.lua @@ -6,6 +6,13 @@ return { opts = {}, --dependencies = { { "echasnovski/mini.icons", opts = {} } }, dependencies = { "nvim-tree/nvim-web-devicons" }, -- use if prefer nvim-web-devicons + config = function() + require("oil").setup({ + view_options = { + show_hidden = true, + }, + }) + end, }, { "nvim-tree/nvim-tree.lua",