From d0b967273018aede83f34ae46723b55295e5d9d8 Mon Sep 17 00:00:00 2001 From: "RingOfStorms (Joshua Bell)" Date: Tue, 11 Apr 2023 11:45:20 -0500 Subject: [PATCH] update --- mappings.lua | 34 ++++++++++++++++++++++++++++++---- plugins/user.lua | 4 ---- 2 files changed, 30 insertions(+), 8 deletions(-) diff --git a/mappings.lua b/mappings.lua index 7a0cc63..7806187 100644 --- a/mappings.lua +++ b/mappings.lua @@ -1,5 +1,5 @@ local scratch = function(extension) - os.execute('mkdir -p ~/dev/scratches/') + os.execute "mkdir -p ~/dev/scratches/" local date = os.date "%Y-%m-%dT%H:%M:%S" local filepath = "~/dev/scratches/scratch_" .. date .. extension vim.cmd("execute 'edit " .. filepath .. "'") @@ -25,20 +25,46 @@ return { ["s"] = { name = " Scratch File" }, ["ss"] = { function() scratch ".txt" end, desc = "New text scratch file" }, ["sn"] = { function() scratch ".json" end, desc = "New json scratch file" }, - ["ss"] = { function() scratch ".sql" end, desc = "New sql scratch file" }, + ["sq"] = { function() scratch ".sql" end, desc = "New sql scratch file" }, ["st"] = { function() scratch ".ts" end, desc = "New ts scratch file" }, ["sb"] = { function() scratch ".sh" end, desc = "New shell scratch file" }, ["sj"] = { function() scratch ".js" end, desc = "New js scratch file" }, + ["∆"] = { + ":m .+1==g", + desc = "Move the line up", + }, + ["˚"] = { + ":m .-2==g", + desc = "Move the line down", + }, }, v = { ["gf"] = { ":OpenInGHFile ", desc = "Open in github" }, ["y"] = { '"*y', desc = "Copy to system clipboard" }, ["p"] = { '"*p', desc = "Paste from system clipboard" }, + ["∆"] = { + cmd = ":m '>+1gv=gv", + desc = "Move the selected text up", + }, + ["˚"] = { + cmd = ":m '<-2gv=gv", + desc = "Move the selected text down", + }, + }, + x = { + ["∆"] = { + cmd = ":m '>+1gv=gv", + desc = "Move the selected text up", + }, + ["˚"] = { + desc = "Move the selected text down", + cmd = ":m '<-2gv=gv", + }, }, i = { - [""] = { "", desc = "Left" }, - [""] = { "", desc = "Down" }, [""] = { "", desc = "Up" }, + [""] = { "", desc = "Down" }, + [""] = { "", desc = "Left" }, [""] = { "", desc = "Right" }, }, c = { diff --git a/plugins/user.lua b/plugins/user.lua index 9a75f9b..8be12fd 100644 --- a/plugins/user.lua +++ b/plugins/user.lua @@ -39,8 +39,4 @@ return { }, cmd = "Glow" }, - -- { - -- "simrat39/inlay-hints.nvim", - -- }, - -- This is not working so disabling for now... }