2 Commits db9f01a561 ... 96b795e82d

Autor SHA1 Mensaje Fecha
  Nikita Chursin 96b795e82d changed blamer plugin hace 4 meses
  Nikita Chursin e199e58284 fixed errs hace 5 meses

+ 1 - 0
lua/ncvim/core_plugins/lua.lua

@@ -2,4 +2,5 @@ ncvim.plugin({
   "folke/lua-dev.nvim",
   "nvim-lua/plenary.nvim",
   "ii14/neorepl.nvim",
+  "ckipp01/stylua-nvim",
 })

+ 14 - 6
lua/ncvim/core_plugins/misc/git.lua

@@ -10,12 +10,20 @@ ncvim.plugin({
     'tpope/vim-fugitive',
   },
   {
-    'APZelos/blamer.nvim',
+    'f-person/git-blame.nvim',
     config = function()
-      vim.g.blamer_enabled = 1
-      vim.g.blamer_show_in_insert_modes = 0
-      vim.g.blamer_template = '<commit-short> - <author>, <author-time>: <summary>'
-      vim.g.blamer_delay = 500
-    end
+      require('gitblame').setup {
+        enabled = true,
+      }
+    end,
   },
+  -- {
+  --   'APZelos/blamer.nvim',
+  --   config = function()
+  --     vim.g.blamer_enabled = 1
+  --     vim.g.blamer_show_in_insert_modes = 0
+  --     vim.g.blamer_template = '<commit-short> - <author>, <author-time>: <summary>'
+  --     vim.g.blamer_delay = 500
+  --   end
+  -- },
 })

+ 23 - 0
lua/ncvim/ui/init.lua

@@ -37,3 +37,26 @@ require('ncvim.ui.statusline')
 require('ncvim.ui.tabline')
 require('ncvim.ui.cursorline')
 require('ncvim.ui.welcome_screen')
+
+local function dumpTable(table, depth)
+  if depth == nil then
+    depth = 0
+  end
+  if (depth > 200) then
+    print("Error: Depth > 200 in dumpTable()")
+    return
+  end
+  for k, v in pairs(table) do
+    if (type(v) == "table") then
+      print(string.rep("  ", depth) .. k .. ":")
+      dumpTable(v, depth + 1)
+    else
+      print(string.rep("  ", depth) .. k .. ": ", v)
+    end
+  end
+end
+
+
+ncvim.debug = {
+  dump = dumpTable,
+}

+ 16 - 12
lua/ncvim/ui/tabline.lua

@@ -109,7 +109,7 @@ ncvim.plugin {
     local get_window_buffer = function(window)
       local success, buff_nr = pcall(vim.api.nvim_win_get_buf, window.number)
       if success == false then
-        print("tab err: " .. buff_nr)
+        -- print("tab err: " .. buff_nr)
         return nil
       end
       return buffersApi.get_buffer(buff_nr)
@@ -165,6 +165,8 @@ ncvim.plugin {
     end
 
     require('cokeline').setup({
+      show_if_buffers_are_at_least = 2,
+
       default_hl = {
         fg = function(tabpage)
           return
@@ -197,18 +199,20 @@ ncvim.plugin {
       },
 
       sidebar = {
-        filetype = { 'NvimTree', 'neo-tree' },
-        components = {
-          {
-            text = function(buf)
-              return "Files"
-            end,
-            fg = highlight.inactive.fg,
-            bg = function() return get_hex('NvimTreeNormal', 'bg') end,
-            bold = true,
-          },
-        }
       },
+      -- sidebar = {
+      --   filetype = { 'NvimTree', 'neo-tree' },
+      --   components = {
+      --     {
+      --       text = function(buf)
+      --         return "Files"
+      --       end,
+      --       fg = highlight.inactive.fg,
+      --       bg = function() return get_hex('NvimTreeNormal', 'bg') end,
+      --       bold = true,
+      --     },
+      --   }
+      -- },
 
       tabs = {
         placement = "left",