Skip to content

[Feature request] Add setting to enable maximum column for TSV hyghlighting #2915

@jrom99

Description

@jrom99

The following file

TSV file, with bat --wrap never notes.tsv:
image

Same file, with bat --wrap never --tabs 0 notes.tsv:
image

I'm not sure what is causing the misalignment bug, but my problem is that some columns data is a lot wider than their headers, and I'd like bat to have a setting to use the largest visible width for these, since setting --tabs to an arbitrary big value applies to all columns.

I tried using column -ts $'\t' notes.tsv | bat -l tsv to columnate the data, but then bat doesn't understand the file:

image

But column -ts $'\t' -o $'\t' notes.tsv | bat -l tsv --wrap never --tabs 0 seems to work, but I think it'd be better to have it as a setting.

System information

bat 0.23.0
GNOME Terminal 3.49.92 using VTE 0.74.0 +BIDI +GNUTLS +ICU +SYSTEMD
Ubuntu 23.10 (Gnome 45 on Wayland)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions