A collection of Python utility scripts.
To set up the project on your local machine, follow these steps:
python -m venv venv
source venv/bin/activate # On Windows use `venv\Scripts\activate`
Make sure you have Python installed. Then, install the required dependencies:
pip install -r requirements.txt
Instructions on the usage of the scripts:
- Generally, just run each script with the option -h to learn about it.
- Rename the file .env.sample to .env and put any necessary environment variables there.
- Be careful about API quota usage.
- There can be error message about relative imports when running a script. In that case, you need to run the script with python -m (check example below)
Calculate the total duration of videos inside a specified directory (and its subdirectories).
python calculate_videos_duration.py -h
Recursively list all files with specified extension and created within a time frame inside specified directory.
Calculate total duration of videos in a YouTube playlist.
python -m youtube.playlist_duration -h
This project is licensed under the Apache License 2.0. You are free to use, modify, and distribute this software under the terms of the license.
For questions or issues, feel free to open an issue in this repository or contact me via email.