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

fix(snipmate): correctly escape backtick #604

Merged
merged 1 commit into from
Sep 20, 2022

Conversation

danilshvalov
Copy link
Contributor

Let's have the following snippet:

snippet src
	\`\`\`$1
	$0
	\`\`\`

Without this patch, it will expand into:

\`\`\`

\`\`\`

After this fix, it will expand into what is expected:

```

```

@L3MON4D3
Copy link
Owner

Thank you for making a PR for this :)

Are you up for adding a test to ensure this doesn't regress?
You should be able to run current test via just make test, and can append a new test for this in tests/integration/parser_spec.lua

@L3MON4D3
Copy link
Owner

Nice :)
One more test for the edge-case I mentioned? (\\\` inside regular backticks)
(And could you squash the commits after?)

@danilshvalov
Copy link
Contributor Author

Nice :) One more test for the edge-case I mentioned? (\\\` inside regular backticks) (And could you squash the commits after?)

Done

@danilshvalov danilshvalov force-pushed the fix-backtick-escape branch 2 times, most recently from 0641793 to 5bb55f0 Compare September 20, 2022 07:05
@L3MON4D3
Copy link
Owner

Yup, ty!

@L3MON4D3 L3MON4D3 merged commit d36c063 into L3MON4D3:master Sep 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants