Collapse
In software development it is a common occurrence to have files that are generated from other files.
- Lockfiles are generated from package manifests.
- Source maps are generated from source code.
- Classes are generated by compilers parsing the source code.
- Code files are generated by transpilers converting code in another language.
pls
has the novel ability for you to define the collapsing rules for these
derived files so that they are both listed together with their source, and also
depicted in a way that emphasises their dependency relationship.
pls
can also nest collapsed nodes into other collapsed nodes, forming a full
tree of collapses.
Arguments
--collapse
/-c
can be used to turn collapsing on or off. pls
enables this
collapsing behaviour by default.
Examples
Cargo.toml └─ Cargo.lock
Cargo.lock Cargo.toml
Configuration
Using the configuration system, you can both change the appearance of the tree and also define additional rules for collapsing in addition to the built-in ones.
Examples
Here is an example showing nested collapses. It uses simple ASCII characters to render colorful collapse trees.
a +-- b | +-- c | +-- .d +-- e .pls.yml