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(complete): Escape special characters properly for zsh #4848

Merged
merged 1 commit into from
Apr 20, 2023

Conversation

changhc
Copy link
Contributor

@changhc changhc commented Apr 19, 2023

Closes #4751.

The original problem is because of unescaped colons, which is included in this PR. However, there are other characters that might cause similar issues, such as backticks and dollar signs. I don't think one would expect something like $PATH to be expanded when he or she puts it in a helper string.

Added a few test cases for unit testing. I think we should add integration tests for this, i.e., help strings from comments, but I'm not sure how to do it.

.github/renovate.json5 Outdated Show resolved Hide resolved
@changhc changhc force-pushed the fix-escape-zsh branch 3 times, most recently from 3b6c4c0 to 709602a Compare April 20, 2023 05:28
@epage epage merged commit 3bc32de into clap-rs:master Apr 20, 2023
@changhc changhc deleted the fix-escape-zsh branch April 20, 2023 21:01
@epage
Copy link
Member

epage commented Apr 21, 2023

Sorry, forgot to release this. Its now out

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.

Markdown links in the help message of a value enum causes ZSH completion to error
2 participants