github juanra/audiobook-forge v2.7.0
v2.7.0: Auto-Detection & File Logging Fixes

latest releases: v2.8.1, v2.8.0
11 hours ago

🐛 Bug Fixes

Auto-Detection for Book Folders (Issue #3)

Fixed --root parameter detection when pointing directly to an audiobook folder:

  • Previously failed: audiobook-forge build --root "/path/to/My Book"
  • Now auto-detects when --root points to a book folder (not a library folder)
  • Lowered detection threshold from 2 to 1 audio file (supports single-file audiobooks)
  • Added is_audiobook_folder() helper function for directory classification

File Logging Implementation (Issue #4)

Implemented file logging - config options now work as documented:

  • Added tracing-appender dependency for file logging with daily rotation
  • Config options (log_to_file, log_file, log_level) now fully functional
  • Default log location: ~/.audiobook-forge/logs/audiobook-forge.log
  • Supports both console and file logging simultaneously

🎉 New Features

Verbose Progress Logging

Enhanced logging throughout processing pipeline - track every step with detailed progress:

  • Shows FFmpeg commands at DEBUG level (useful for troubleshooting)
  • File-by-file encoding progress with duration estimates
  • Chapter injection status with count and completion messages
  • Metadata injection logging with AtomicParsley commands
  • Processing time tracking (start/completion with elapsed time)
  • INFO level: User-facing progress updates
  • DEBUG level: Technical details including full commands

Example Verbose Output:

[2025-12-21 10:30:45] INFO  === Starting book processing: The Great Audiobook ===
[2025-12-21 10:30:45] INFO  [1/12] Encoding: chapter1.mp3 (25.3 min)
[2025-12-21 10:30:52] INFO  [2/12] Encoding: chapter2.mp3 (18.7 min)
[2025-12-21 10:35:15] INFO  All 12 files encoded, now concatenating...
[2025-12-21 10:38:42] INFO  Injecting 12 chapters using MP4Box
[2025-12-21 10:38:43] INFO  ✓ Chapter injection complete
[2025-12-21 10:38:43] INFO  Injecting metadata using AtomicParsley
[2025-12-21 10:38:44] INFO  ✓ Metadata injection complete
[2025-12-21 10:38:44] INFO  === Completed: The Great Audiobook in 479.2s ===

Enable Verbose Logging:

# Console only (INFO level)
audiobook-forge build --verbose

# To file (configure in ~/.audiobook-forge/config.yaml)
log_to_file: true
log_level: DEBUG  # or INFO, WARNING, ERROR

📝 Technical Details

Files Modified:

  • src/cli/handlers.rs - Fixed auto-detection logic
  • src/main.rs - Implemented layered file logging
  • src/core/processor.rs - Added progress logging at all key steps
  • src/audio/ffmpeg.rs - Added FFmpeg command logging
  • src/audio/metadata.rs - Added AtomicParsley command logging
  • src/audio/chapters.rs - Added chapter generation logging
  • Cargo.toml - Added tracing-appender dependency

Issue References:

  • Fixes #3: No files found when --root is a book folder
  • Fixes #4: Logging to file not working

📦 Installation

cargo install audiobook-forge

Or download pre-built binaries from the releases page.


❤️ Support this project: If you find audiobook-forge useful, consider sponsoring development!

Don't miss a new audiobook-forge release

NewReleases is sending notifications on new releases.