Skip to content

Entries in table aren't clearly separated #1

@LordMZTE

Description

@LordMZTE

Consider:

> [[foo, bar]; [1, 2], [3, 4]] | tree

└── value
    ├── foo
    │   └── 1
    ├── bar
    │   └── 2
    ├── foo
    │   └── 3
    └── bar
        └── 4

Here, the tree output does not make it clear that 1 2 and 3 4 are separate rows. Instead, a somewhat confusing notation is used where it looks like we have "duplicate keys".

Here are some suggestions on how I think this output could be improved:

# We could use a sort of separator line
└── value
    ├── foo
    │   └── 1
    ├── bar
    │   └── 2
    ├──----------------------------------
    ├── foo
    │   └── 3
    └── bar
        └── 4

# We could make the rows separate entries in the tree
└── value
    ├── 0
    │   ├── foo
    │   │   └── 1
    │   └── bar
    │       └── 2
    └── 1
        ├── foo
        │   └── 3
        └── bar
            └── 4

I think I prefer the former approach as this minimizes unecessary extra tree depth.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions