folke / ts-comments.nvim

Tiny plugin to enhance Neovim's native comments
Apache License 2.0
321 stars 23 forks source link

bug: Default commentstring for languages without ftplugins #53

Open smartinellimarco opened 1 month ago

smartinellimarco commented 1 month ago

Did you check docs and existing issues?

Neovim version (nvim -v)

0.10.1

Operating system/version

MacOS 14.3

Describe the bug

Hi there,

I've noticed that languages like Terraform don't have a ftplugin available yet (it's in the process of being added from Vim source). Because of this, the plugin isn't working properly for uncommenting.

It would be great if we could set a default comment string directly in this plugin.

Thanks for considering this!

Steps To Reproduce

  1. Comment a block in a tf file
  2. It should say commentstring is empty

Expected Behavior

The code should be uncommented

Repro

vim.env.LAZY_STDPATH = ".repro"
load(vim.fn.system("curl -s https://raw.githubusercontent.com/folke/lazy.nvim/main/bootstrap.lua"))()

require("lazy.minit").repro({
  spec = {
    { "folke/ts-comments.nvim", opts = {} },
    -- add any other plugins here
  },
})
github-actions[bot] commented 4 weeks ago

This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.

smartinellimarco commented 4 weeks ago

not stale