Skip to content

treefmt ignores files which are untracked but not gitignored #557

@michaelpj

Description

@michaelpj

Describe the bug

If you have a file which is not yet tracked by git, but which is not gitignored, then treefmt does not format it (because it doesn't show up in git ls-files).

I think this could be fixed by passing -o to git ls-files.

To Reproduce

Steps to reproduce the behavior:

  1. Add a new file
  2. Don't git add it
  3. Run treefmt

Expected behavior

I would expect it to be formatted.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions