Get a SQLite database of a directory tree.
The data retrieved includes:
- File sizes and modification date.
- Folder sizes and file counts.
- Recursive (including sub-folders) folder sizes and file counts.
To create the database and execute some example queries listing largest files and folders:
from directory_to_sql import get_db, top_10
conn = get_db(search_path='\\', database='db.db')
top_10(conn)
The latest released version is available on the Python Package Index.
pip install directory_to_sql