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

Improve handling of delimiters with backslashes #403

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Improve handling of delimiters with backslashes #403

wants to merge 1 commit into from

Conversation

roryrjb
Copy link
Contributor

@roryrjb roryrjb commented Oct 26, 2019

This pull request has been opened to address issue #402 I raised separately.

As mentioned in the issue description, I recently added delimiter definitions for troff family languages, which included, for the first time backslashes:

\# 	" groff
.\" 	" troff / mandoc

...but these aren't handled correctly in some cases. Currently the plugin can add them but they won't be detected when trying to remove them, so they get added again.

This pull request is trying to solve this, although it might not be in the best way and others may have a better solution to this, but of course if I can contribute then I'll try to.

@roryrjb
Copy link
Contributor Author

roryrjb commented Oct 26, 2019

Just wanted to add that the definition for troff/mandoc probably should be .\" rather than the .\\" currently and this pull request relies on this.

Also this pr doesn't actually fix the issue with groff \#. Again someone else might have a better solution for this, but I will try to come up with some additional fixes in the meantime. If I do get something together that is better I will tidy up and squash this pr.

@alerque
Copy link
Member

alerque commented Oct 26, 2019

Thanks for the report and the attempt to fix ti @roryrjb. I'm not entirely sure myself how this should be fixed. Also I won't have time to dig into it for at least a few days.

As I understand it this PR currently fixes troff but not groff right?

Also I would suggest going ahead and adding a commit to this PR that changes the default delimiter for troff/mandoc if you think you can make the case for the default change being for the best.

@roryrjb
Copy link
Contributor Author

roryrjb commented Oct 26, 2019

@alerque that's correct, this only fixes troff but I'm going to see if I can fix groff too. I'll also see if changing the delimiters for troff and mandoc will improve things, because I think that will make them closer to groff and all can be fixed in the same way.

@alerque
Copy link
Member

alerque commented Dec 21, 2019

What's the status on this @roryrjb? Let me know when I should give this another review. Sorry I wasn't very available back when it came in, if you need something let me know.

@roryrjb
Copy link
Contributor Author

roryrjb commented Dec 28, 2019

@alerque hey, I haven't had much time but still want to crack this, especially as I'm working with troff this weekend. I'm hoping to have a fix very soon, will let you know. Hope you had a good Christmas and all the best for 2020!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants