bluz71 / nvim-linefly

A simple Lua statusline for Neovim
MIT License
85 stars 2 forks source link

[BUG] nvim-dap-ui window names #8

Closed serranomorante closed 9 months ago

serranomorante commented 9 months ago

Thank you so much for this plugin!

Description

nvim-dap-ui windows lose their original names

image

image

Reproducible steps

for _, name in ipairs({ "config", "data", "state", "cache" }) do
  vim.env[("XDG_%s_HOME"):format(name:upper())] = "/tmp/nvim-debug-issue/" .. name
end

vim.g.mapleader = " "

local plugins = {
  {
    "rcarriga/nvim-dap-ui",
    dependencies = "mfussenegger/nvim-dap",
    lazy = false,
    keys = {
      {
        "<leader>du",
        function() require("dapui").toggle() end,
        desc = "Toggle Debugger UI",
      },
    },
    config = true,
  },

  {
    "bluz71/nvim-linefly",
    enabled = true
  },
}

--------------------------------------------------------------------------------

local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
  vim.fn.system({
    "git",
    "clone",
    "--filter=blob:none",
    "https://github.com/folke/lazy.nvim.git",
    "--branch=stable",
    lazypath,
  })
end
vim.opt.runtimepath:prepend(lazypath)
require("lazy").setup(plugins)
  1. copy the previous snippet in a file, lets say debug-issue.lua
  2. open with nvim --clean +'so debug-issue.lua'. Don't worry, it won't mess up with your home directory (see line 2)
  3. press <leader>du to bring the nvim-dap-ui windows

You will notice the issue with window names

(then, if you change enabled = false on line 24 you will see the window names as expected)

btw, I love that this plugin renames the tabs to Tab:1 šŸ’– nice touch!

bluz71 commented 9 months ago

Thanks for the detailed report.

I have now added in support for nvim-dap-ui including handling these cases:

Let me know how if you have any issues since I only carried out basic tests.

serranomorante commented 9 months ago

Working great! Thanks šŸ’–