Skip to content

TreeOptions

🛈 DocStrings

Configuration options for directory tree printing.

Source code in src/jinjarope/filetree.py
@dataclass
class TreeOptions:
    """Configuration options for directory tree printing."""

    show_hidden: bool = False
    show_size: bool = True
    show_date: bool = False
    show_permissions: bool = False
    show_icons: bool = True
    max_depth: int | None = None
    include_pattern: Pattern[str] | None = None
    exclude_pattern: Pattern[str] | None = None
    allowed_extensions: set[str] | None = None
    hide_empty: bool = True
    sort_criteria: SortCriteria = SortCriteria.NAME
    reverse_sort: bool = False
    date_format: str = "%Y-%m-%d %H:%M:%S"

:fa-brands-github: Show source on GitHub