https://github.com/jrs296/directory-tree
Simple Python CLI App to generate a directory tree for a given path
https://github.com/jrs296/directory-tree
pypi-package python-cli tree-generation
Last synced: 10 months ago
JSON representation
Simple Python CLI App to generate a directory tree for a given path
- Host: GitHub
- URL: https://github.com/jrs296/directory-tree
- Owner: JRS296
- License: mit
- Created: 2023-07-06T16:48:37.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2023-07-07T07:23:00.000Z (over 2 years ago)
- Last Synced: 2025-02-07T01:46:13.226Z (10 months ago)
- Topics: pypi-package, python-cli, tree-generation
- Language: Python
- Homepage: https://pypi.org/project/treGen/
- Size: 30.3 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.txt
- License: LICENSE
Awesome Lists containing this project
README
# treeGen - A directory Tree Generator
Simple Python CLI App to generate a directory tree for a given path
## Current TaskList
- [ ] Add support for sorting files and directories
- [ ] Add icons and colors to the tree diagram
- [X] Set up the application to publish it as an open source project
## Run the App
To run **treGen**, you need to intall it via pip:
1. Create and activate a Python virtual environment
```sh
pip install treGen
```
**Note:** The `-h` or `--help` option provides help on how to use treGen.
To take a quick test on **treGen**, you can use the sample `home/` directory provided along with the application's code and run the following command:br
```sh
PS D:\CompSci - Learn\Python\Root_Tree_Generator> treGen "D:\CompSci - Learn\Python\GenTreeRoot"
D:\CompSci - Learn\Python\GenTreeRoot\
│
├── src\
│ ├── cli.py
│ ├── treeGen.py
│ └── __init__.py
│
├── CHANGELOG.txt
├── LICENSE
├── MANIFEST.in
├── README.md
├── setup.py
└── test.py
```
That's it! You've generated a nice directory tree diagram.
## Current Features
If you run treGen with a directory path as an argument, then you get the full directory tree printed on your screen. The default input directory is your current directory.
treGen also provides the following options:
- `-v`, `--version` shows the application version and exits
- `-h`, `--help` show a usage message
- `-d`, `--dir-only` generates a directory-only tree
- `-o`, `--output-file` generates a tree and save it to a file in markdown format
## Release History
- 0.1.0
- 1.0.0
- 2.0.0
- Serious breaking issues with console scripts
- 3.0.0
- Finally got the setup.py to work xD
- 4.0.0
- A work in progress
## About the Author + Original Fork Address
Leodanis Pozo Ramos - Email: leodanis@realpython.com
A fork from [https://github.com/realpython/materials/tree/master/directory-tree-generator-python](https://github.com/realpython/materials/tree/master/directory-tree-generator-python)