summaryrefslogtreecommitdiff
path: root/init.lua
diff options
context:
space:
mode:
authorbeeb5k (Vivek Tiwari) <beebeeb5k@gmail.com>2026-06-04 20:25:23 +0530
committerbeeb5k (Vivek Tiwari) <beebeeb5k@gmail.com>2026-06-04 20:25:23 +0530
commitbfe5ef76b95725451707f6061d5dfa5e3b024c61 (patch)
treee61fd46ffbb77e131edbc0ffe1019cef2d7662a9 /init.lua
parent3ab5bbeda2c86b62999b5a662374c38e3ef0c01b (diff)
Use better Plugins
- codediff - neogit - nvim-surround - hlchunk - fff.nvim - gitsigns
Diffstat (limited to 'init.lua')
-rw-r--r--init.lua42
1 files changed, 21 insertions, 21 deletions
diff --git a/init.lua b/init.lua
index 596c4ed..71fcc9d 100644
--- a/init.lua
+++ b/init.lua
@@ -1,27 +1,27 @@
string.relpath = function(str, sub, n)
- local result = {}
- n = type(sub) == "string" and n or sub
- if type(n) == "number" and n > 0 then
- for match in (str .. "."):gmatch("(.-)%.") do
- table.insert(result, match)
- end
- while n > 0 do
- table.remove(result)
- n = n - 1
- end
- else
- table.insert(result, str)
- end
- if type(sub) == "string" then
- table.insert(result, sub)
- end
- return #result == 1 and result[1] or table.concat(result, ".")
+ local result = {}
+ n = type(sub) == "string" and n or sub
+ if type(n) == "number" and n > 0 then
+ for match in (str .. "."):gmatch("(.-)%.") do
+ table.insert(result, match)
+ end
+ while n > 0 do
+ table.remove(result)
+ n = n - 1
+ end
+ else
+ table.insert(result, str)
+ end
+ if type(sub) == "string" then
+ table.insert(result, sub)
+ end
+ return #result == 1 and result[1] or table.concat(result, ".")
end
if not table.pack then
- table.pack = function(...)
- return { n = select("#", ...), ... }
- end
+ table.pack = function(...)
+ return { n = select("#", ...), ... }
+ end
end
vim.loader.enable()
@@ -32,5 +32,5 @@ vim.g.netrw_liststyle = 0
vim.g.netrw_banner = 0
if vim.g.vscode == nil then
- require("bee")
+ require("bee")
end