From 67be5961549bde156dc0b8af2bc89c336503e1a9 Mon Sep 17 00:00:00 2001 From: blob42 Date: Mon, 30 Jan 2023 22:13:34 +0100 Subject: [PATCH] fix global modules to local --- lua/custom/plugins/configs/lsp_signature.lua | 2 +- lua/custom/plugins/configs/luasnip.lua | 1 + lua/custom/plugins/configs/marks.lua | 2 +- lua/custom/plugins/configs/todo-comments.lua | 2 +- lua/spike/dap/dapmode.lua | 2 +- notes/Tips.md | 7 ++++++- 6 files changed, 11 insertions(+), 5 deletions(-) diff --git a/lua/custom/plugins/configs/lsp_signature.lua b/lua/custom/plugins/configs/lsp_signature.lua index e1f82b0..09a9a06 100644 --- a/lua/custom/plugins/configs/lsp_signature.lua +++ b/lua/custom/plugins/configs/lsp_signature.lua @@ -10,7 +10,7 @@ local config = { } -M = {} +local M = {} M.setup = function() signature.setup(config) end diff --git a/lua/custom/plugins/configs/luasnip.lua b/lua/custom/plugins/configs/luasnip.lua index be6aa8a..d7f0edf 100644 --- a/lua/custom/plugins/configs/luasnip.lua +++ b/lua/custom/plugins/configs/luasnip.lua @@ -4,6 +4,7 @@ if not present then return end +local M = {} local types = require("luasnip.util.types") local options = { diff --git a/lua/custom/plugins/configs/marks.lua b/lua/custom/plugins/configs/marks.lua index e68189e..0ca8240 100644 --- a/lua/custom/plugins/configs/marks.lua +++ b/lua/custom/plugins/configs/marks.lua @@ -5,7 +5,7 @@ if not present then end -M = {} +local M = {} local config = { bookmark_0 = { diff --git a/lua/custom/plugins/configs/todo-comments.lua b/lua/custom/plugins/configs/todo-comments.lua index 41ad961..efcfe36 100644 --- a/lua/custom/plugins/configs/todo-comments.lua +++ b/lua/custom/plugins/configs/todo-comments.lua @@ -4,7 +4,7 @@ if not present then return end -M = {} +local M = {} local config = { keywords = { diff --git a/lua/spike/dap/dapmode.lua b/lua/spike/dap/dapmode.lua index 8dd131b..c785361 100644 --- a/lua/spike/dap/dapmode.lua +++ b/lua/spike/dap/dapmode.lua @@ -1,7 +1,7 @@ local libmodal = require 'libmodal' local daputils = require 'spike.dap.utils' -M = {} +local M = {} M.layer = nil diff --git a/notes/Tips.md b/notes/Tips.md index 438c16f..61141d5 100644 --- a/notes/Tips.md +++ b/notes/Tips.md @@ -43,7 +43,7 @@ as global variable :bufdo — Execute the command in each buffer in the buffer list :tabdo — Execute the command in each tab page :windo — Execute the command in each window -:cdo — Execute the command in each valid entry in the quickfix list +:cdo — Execute the command in each valid entry in the quickfix list (entry itself not the file) :cfdo — Execute the command in each file in the quickfix list :vimgrep `:vimgrep // ##` where ## is replaces with files in arg list @@ -51,3 +51,8 @@ as global variable `packadd cfilter` `:Cfilter /pattern/` `:Lfilter /pattern` + +## Delete lines matching pattern +!! Use the :global command + + :g/profile/d