kndndrj / nvim-dbee

Interactive database client for neovim

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

show column number on `relativenumber` options

hieulw opened this issue · comments

image

Hello my options have vim.opt.relativenumber = true. How can I disable line number in dbee-drawer, dbee-call-log, dbee-result. They don't have custom buftype or filetype to customize by autocmd, they're just filename

Yeah, this is something that was lost in the refactor. The pre-refactor version had window_layout hooks that could be used for this exact purpose. Post-refactor, you have to implement an entire layout which isn't ideal if you're just trying to set some window options.

You can create autocmds for the filenames, e.g.

vim.api.nvim_create_autocmd("WinNew", {
  pattern = "dbee-call-log",
  callback = function()
    -- do whatever you want in here, e.g.
    vim.wo.relativenumber = true
  end
})

however this doesn't always work. For example, when first opening the dbee ui these autocmds don't fire (or they do but get overwritten by dbee, not sure which, or why). They do fire upon re-opening the dbee ui - at least in my setup. Specifically for dbee-result, this one never seems to hit for me.

Anyways, I too would like to be able to set a few options for each of these windows. Maybe we can convince @kndndrj to add the old window_layout hooks back, or the old window_commands, or just something that's lets you specify some custom window opts for each of these tiles 😜

Window/buffer options sure would make sense.