0.15.0-1 merger

This commit is contained in:
2026-04-22 20:32:47 +00:00
parent 1f0a357abf
commit 120a9e6ad1
16 changed files with 728 additions and 197 deletions
+27 -1
View File
@@ -93,8 +93,34 @@ function parseCdParanoiaProgress(line) {
return null;
}
function parseMkvmergeProgress(line) {
const normalized = String(line || '').replace(/\s+/g, ' ').trim();
if (!normalized) {
return null;
}
// Common mkvmerge output examples:
// "Progress: 42%"
// "#GUI#progress 42%"
const explicitMatch = normalized.match(/(?:^|\s)(?:progress:?|#GUI#progress)\s*(\d{1,3}(?:\.\d+)?)\s*%/i);
if (explicitMatch) {
return {
percent: clampPercent(Number(explicitMatch[1])),
eta: null
};
}
const percent = parseGenericPercent(normalized);
if (percent !== null) {
return { percent, eta: null };
}
return null;
}
module.exports = {
parseMakeMkvProgress,
parseHandBrakeProgress,
parseCdParanoiaProgress
parseCdParanoiaProgress,
parseMkvmergeProgress
};