semvec/pypi-packages huggingface dataset:
pydirtree 1.0.5
Print a directory tree structure in your Python code.
Keywords: python,directory,tree,structure,print,display

# py-dir-tree

Print a directory tree structure in your Python code.

## Download

You can simply:

```sh
pip install pydirtree
```

Or:

1. Clone the repository to your local machine.
2. Enter the directory.
3. Download necessary modules/libraries.

```sh
git clone https://github.com/gabrielstork/py-dir-tree.git
cd py-dir-tree
pip install -r requirements.txt
```

## Examples

When `complete=True`:

```python
from pydirtree import Tree

path = Tree('C:/Users/User/Desktop/py-dir-tree', complete=True)
print(path)
```

```text
📂 C:
|_📂 Users
  |_📂 User
    |_📂 Desktop      
      |_📂 py-dir-tree
        |_📁 .git     
        |_📁 pydirtree
        |_📄 LICENSE  
        |_📄 README.md
        |_📄 requirements.txt
        |_📄 setup.py
```

When `complete=False`:

```python
from pydirtree import Tree

path = Tree('C:/Users/User/Desktop/py-dir-tree', complete=False)
print(path)
```

```text
📂 py-dir-tree
|_📁 .git
|_📁 pydirtree
|_📄 LICENSE
|_📄 README.md
|_📄 requirements.txt
|_📄 setup.py
```