Skip to content

Cannot have newline in a delimiter #405

Open
@lukelbd

Description

@lukelbd

In RST, the proper way to comment out lines is by prefixing them with a .. followed by a newline and two spaces:

..
  This is a comment.
  It will not appear in the document.

The default NERDComment behavior just prefixes this with .., i.e.

.. This *might* be a comment.

but this behavior is discouraged, since RST will "interpret" the comment if it starts with a particular keyword.

I tried setting

let g:NERDCustomDelimiters = {'rst': {'left': "..\n  "}}

but that ends up replacing the newline with a null character ^@.

Is there a way to get NERDCommenter to respect delimiters with newline characters / to propertly comment out RST text?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions