A command-line tool for managing MP3 files, converting audio formats, and working with ID3 metadata tags.
cargo build --releaseThe binary will be available at target/release/library-manager.
- ffmpeg - Required for WAV to MP3 conversion
- macOS: 
brew install ffmpeg - Linux: 
apt-get install ffmpegoryum install ffmpeg - Windows: Download from ffmpeg.org
 
 - macOS: 
 
Process MP3 files in a directory structure and set genre tags based on folder names.
Usage:
library-manager prepare --directory <PATH>
library-manager prepare -d <PATH>Description:
- Scans the specified directory for subdirectories
 - For each subdirectory, processes all MP3 files inside
 - Sets the genre tag of each MP3 file to match the folder name
 
Example:
library-manager prepare --directory /path/to/musicIf your music is organized like:
/path/to/music/
├── Rock/
│   ├── song1.mp3
│   └── song2.mp3
└── Jazz/
    └── song3.mp3
All files in the Rock folder will have their genre set to "Rock", and files in Jazz will be set to "Jazz".
Convert a WAV file to MP3 format.
Usage:
library-manager convert --input <FILE> [--bitrate <BITRATE>]
library-manager convert -i <FILE> [-b <BITRATE>]Options:
--input, -i- Path to the input WAV file (required)--bitrate, -b- Bitrate for MP3 encoding in kbps (default: 320)
Description:
- Converts a WAV file to MP3 format
 - Output file is created in the same directory with the same name but 
.mp3extension - Automatically preserves the original audio properties (sample rate, channels)
 - Uses ffmpeg for conversion
 
Examples:
# Convert with default 320k bitrate
library-manager convert --input song.wav
# Convert with custom 192k bitrate
library-manager convert --input song.wav --bitrate 192
# Using short flags
library-manager convert -i song.wav -b 256Common Bitrates:
- 128k - Acceptable quality, smaller files
 - 192k - Good quality
 - 256k - Very good quality
 - 320k - Maximum MP3 quality (default)
 
Display metadata information from an MP3 file.
Usage:
library-manager info --file <FILE>
library-manager info -f <FILE>Description:
- Reads and displays ID3 metadata tags from an MP3 file
 - Shows information such as title, artist, album, genre, track numbers, duration, and embedded images
 
Example:
library-manager info --file song.mp3Sample Output:
Metadata for: song.mp3
============================================================
Title:        My Song
Artist:       The Artist
Album:        The Album
Genre:        Rock
Year:         2024
Track:        5/12
Duration:     3:45
Pictures:     1 embedded image(s)
============================================================
--help, -h- Display help information for any command--version, -V- Display version information
Examples:
library-manager --help
library-manager prepare --help
library-manager --version[Add your license here]
[Add contributing guidelines here]