Skip to content

Add support to follow .gitignore (or custom .treefmtignore) file for ignoring files or directories? #198

@aldoborrero

Description

@aldoborrero

Rationale

Sometimes, you want to exclude directories that don't belong to any specific language but rather because you don't want treefmt to traverse those. As far as I'm aware, you need to exclude those from one specific formatter.

Note: There's global support for ignoring directories.

We can add support to follow the .gitignore options or if .treefmtignore is present, add those directories to the global config.

We can achieve a similar behaviour by leveraging something like gitignore crate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions