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

Breaks on columns containing whitespace #2

Open
yangmillstheory opened this issue Mar 18, 2017 · 2 comments
Open

Breaks on columns containing whitespace #2

yangmillstheory opened this issue Mar 18, 2017 · 2 comments

Comments

@yangmillstheory
Copy link

image

Happens in alacritty and iterm2.

@lonetwin
Copy link
Owner

@yangmillstheory Thanks for the bug report.

Unfortunately, I am not sure how to address this issue. Since strictly speaking the command is actually separating the individual lines by spaces and then applying the colors to what it assumes are different columns. (IOW, it is working as advertised, even if it isn't what you expect). For example, in the first line of the attached screenshot "CONTAINTER" and "ID" are being treated as the first and second columns, so this entire line appears as tho' it is shifted by one column color as compared to the next line and so on ...

For the command to be able to understand columns, I'd have to add more complexity, for example in terms of additional options specifying the fields (or field lengths). For now I'll keep this open and revisit if I have a good solution in mind.

PR of course are welcome. Thanks again !

lonetwin added a commit that referenced this issue Mar 27, 2017
Updated the `-c` option to recognize an optional width specification.

The `-c` option now can accept:

  * a list of colors eg: `-c red,blue,green`
  * a list of column widths eg: `-c :10,:20,:15`
  * or a mix of both eg: `-c red:10,blue,green:12`
@lonetwin
Copy link
Owner

@yangmillstheory The latest release attempts to provide a fix for this issue by adding an optional width parameter to the -c option. Please try it out and let me know whether that sounds like a good solution for you. Appreciate your feedback !

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

No branches or pull requests

2 participants