Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lekoarts/media-stats-rs
Generate a table with media statistics of video files in a folder
https://github.com/lekoarts/media-stats-rs
cli ffmpeg ffprobe media rust statistics
Last synced: 4 days ago
JSON representation
Generate a table with media statistics of video files in a folder
- Host: GitHub
- URL: https://github.com/lekoarts/media-stats-rs
- Owner: LekoArts
- License: mit
- Created: 2024-12-30T14:50:31.000Z (17 days ago)
- Default Branch: main
- Last Pushed: 2024-12-30T15:44:04.000Z (17 days ago)
- Last Synced: 2025-01-06T18:47:09.920Z (10 days ago)
- Topics: cli, ffmpeg, ffprobe, media, rust, statistics
- Language: Rust
- Homepage:
- Size: 12.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# media-stats-rs
Generate a table with media statistics of video files in a folder. You'll receive information like the resolution or codec to quickly sort and filter your media files. Optionally you can create a `.csv` file with the information.
Uses [`ffprobe`](https://docs.rs/ffprobe/latest/ffprobe/) to inspect the files.
## Installation
You'll need to have the [Rust development environment](https://www.rustup.rs/) installed and up to date.
Once you have rust and dependencies installed, use cargo to install media-stats-rs:
```shell
cargo install --locked media-stats-rs
```## Usage
You need to pass a `base` and `pattern`.
```shell
Usage: media-stats-rs [OPTIONS] --base --patternOptions:
-b, --base The base folder to search in
-p, --pattern The file pattern to search for inside the base folder
-c, --csv Write output to a .csv file in the current directory
-h, --help Print help
-V, --version Print version
```Example:
```shell
media-stats-rs --base "/Users/movies" --pattern "**/*.{mkv,mp4}"
```Output:
```shell
🔍 Searching for files...
+-------------------------------+-------+--------+----------------+-----------+-------+----------+-----------+
| Filename | Width | Height | Duration (min) | Size (GB) | Codec | Audio | Subtitles |
+============================================================================================================+
| Millennium Actress (2001).mkv | 1920 | 1040 | 86 | 9.91 | hevc | ger, jpn | ger |
+-------------------------------+-------+--------+----------------+-----------+-------+----------+-----------+🎬 Total files found: 1
✨ Done in 0 seconds
```