Skip to content

choice of git/non-git-tracked files is unclear #127

Description

@simonmichael

Thank you for tre! I was looking for a tree that lists only directories/files tracked by git. I think you worked towards that in 0.4.0, but there are still some issues. Eg:

~/src$ git clone --depth 1 https://github.com/simonmichael/hledger.git
~/src$ cd hledger/.github
~/src$ mkdir new  # create an uncommitted, unignored directory
~/src/hledger/.github$ git ls-files | grep / | cut -d / -f 1 | uniq  # only two dirs are committed here
ISSUE_TEMPLATE
workflows
~/src/hledger/.github$ tree -d  # tree -d shows committed and uncommitted dirs
.
|-- ISSUE_TEMPLATE
|-- new
`-- workflows
    `-- old

4 directories
~/src/hledger/.github$ tre -d  # tre -d shows committed dirs and uncommitted ignored dirs (old is mentioned in .gitignore)
.
├── ISSUE_TEMPLATE
└── workflows
    └── old
~/src/hledger/.github$ tre --version
tre-command 0.4.0

Wishlist:

  • limiting to git-tracked directories or not would be an option
  • items would not be listed just because they appear in a .gitignore
  • the option affects file listing just the same way
  • the behaviour with respect to git-tracked things is clear in the docs

Activity

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

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