Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tangle bug when filename has dash (-) or underscore (_) #1420

Open
2 tasks done
uyha opened this issue May 13, 2024 · 1 comment
Open
2 tasks done

Tangle bug when filename has dash (-) or underscore (_) #1420

uyha opened this issue May 13, 2024 · 1 comment
Labels
bug Issues related to bugs. Please attach a severity, a priority and category with this label.

Comments

@uyha
Copy link

uyha commented May 13, 2024

Prerequisites

  • I am using the latest stable release of Neovim
  • I am using the latest version of the plugin

Neovim Version

NVIM v0.9.5

Neorg setup

return {
  "nvim-neorg/neorg",
  dependencies = {
    "folke/zen-mode.nvim",
    {
      "vhyrro/luarocks.nvim",
      config = true,
    },
  },
  ft = "norg",
  opts = {
    load = {
      ["core.completion"] = { config = { engine = "nvim-cmp" } },
      ["core.concealer"] = {},
      ["core.defaults"] = {},
      ["core.export"] = {},
      ["core.keybinds"] = { config = { neorg_leader = " " } },
      ["core.presenter"] = { config = { zen_mode = "zen-mode" } },
    },
  },
}

Actual behavior

Have this block of code in an neorg file

#tangle a-a
@code sh
echo dash
@end

Run :Neorg tangle, a file named -a is then created. Having the more than 1 dash makes the tangle skip it entirely.

Expected behavior

A file with the correct name created.

Steps to reproduce

As described in the Actual Behavior section

Potentially conflicting plugins

No response

Other information

No response

Help

None

Implementation help

No response

@uyha uyha added the bug Issues related to bugs. Please attach a severity, a priority and category with this label. label May 13, 2024
@benlubas
Copy link
Contributor

This is a TS parser problem. The same problem that prevents you from giving a path to a sub-directory like that. It's really annoying. It's been around for while. New parser is in development, but things have been paused for a while as people wrap up school and exams.

I'd recommend specifying the file paths in the document meta-data, I know that's limiting, but it's the best workaround for now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Issues related to bugs. Please attach a severity, a priority and category with this label.
Projects
None yet
Development

No branches or pull requests

2 participants