mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-23 01:08:53 +02:00
add: update config
This commit is contained in:
parent
c651a8ca42
commit
a81806cab8
15 changed files with 363 additions and 407 deletions
|
@ -8,6 +8,14 @@ return {
|
|||
end
|
||||
local icons = require("user.icons")
|
||||
|
||||
local getLeftSubstring = function(word, length)
|
||||
if #word > length then
|
||||
return string.sub(word, 1, length) .. "..."
|
||||
else
|
||||
return word
|
||||
end
|
||||
end
|
||||
|
||||
-- start for lsp
|
||||
local list_registered_providers_names = function(filetype)
|
||||
local s = require("null-ls.sources")
|
||||
|
@ -131,7 +139,7 @@ return {
|
|||
|
||||
local get_branch = function()
|
||||
if vim.b.gitsigns_head ~= nil then
|
||||
return icons.git.Branch2 .. " " .. vim.b.gitsigns_head
|
||||
return icons.git.Branch2 .. " " .. getLeftSubstring(vim.b.gitsigns_head, 6)
|
||||
else
|
||||
return icons.git.Branch2 .. vim.fn.fnamemodify("", ":t")
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue