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

Avoid splitting on initial hyphens in --foo-bar #14

Closed
mgeisler opened this issue Jan 16, 2017 · 0 comments

Comments

Projects
None yet
1 participant
@mgeisler
Copy link
Owner

commented Jan 16, 2017

We should only split on hyphens surrounded by non-hyphens or perhaps surrounded by word-characters.

@mgeisler mgeisler added the bug label Jan 16, 2017

mgeisler added a commit that referenced this issue Jan 19, 2017

split_word: avoid splitting "--"
A single or double hyphen in the beginning of a word is not a valid
break-point.

Double hyphens often appear with in texts about long command-line
options such as --dry-run or --ignore-backups.

Fixes #14.

@mgeisler mgeisler closed this in #17 Jan 21, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.