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

Wrapping on long long-description lines with \x05 doesn't work right #277

Open
cpence opened this issue Nov 11, 2012 · 0 comments
Open

Wrapping on long long-description lines with \x05 doesn't work right #277

cpence opened this issue Nov 11, 2012 · 0 comments

Comments

@cpence
Copy link

cpence commented Nov 11, 2012

In the long description wrapping code (around here), the line is wrapped to the width of the terminal before the user's provided \x05 escapes are translated to newlines. This means that if you have a really long block of \x05 delimited text, it will get falsely wrapped somewhere in the middle. E.g., the following long description:

Data file types:
\x05- 
\x05Compressed file types:
\x05- gzip (.gz)
\x05- bzip2 (.bz2)
\x05- xz (.xz)
\x05Archive file types:
\x05- tar (.tar, .tar.gz, .tar.bz2, .tar.xz)
\x05- zip (.zip)

will be output to the terminal something like this:

Data file types: 
- 
Compressed file types: 
- gzip (.gz) 
- bzip2 (.bz2) 
- xz (.xz) 
Archive file 
types: 
- tar (.tar, .tar.gz, .tar.bz2, .tar.xz) 
- zip (.zip)

Note the extra wrap between "Archive file" and "types:" -- that's (I presume) 100 characters into the string, the terminal width. If the user's \x05s were converted to newlines before the terminal-width wrapping, this would look right.

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

No branches or pull requests

1 participant