ffmpeg-progressbar-cli
Advanced tools
Comparing version 1.1.2 to 1.2.2
@@ -46,2 +46,3 @@ #!/usr/bin/env node | ||
const formatter = require('./formatter') | ||
const theme = require('./theme') | ||
@@ -186,6 +187,7 @@ | ||
if ((parseFFmpegLog.question(data.toString()))) { | ||
// Handle Questions | ||
process.stdout.write(parseFFmpegLog.question(data.toString())) | ||
// Question: Show Question + whitespace | ||
process.stdout.write(theme.prompt(parseFFmpegLog.question(data.toString().trim()))) | ||
process.stdout.write(' ') | ||
} else { | ||
// Handle other errors | ||
// Errors: Persist | ||
const dataLines = data.toString().trim().split(os.EOL) | ||
@@ -213,3 +215,3 @@ lastError = dataLines[dataLines.length - 1] | ||
if (lastError) { | ||
process.stderr.write(lastError) | ||
process.stderr.write(theme.error(lastError)) | ||
} | ||
@@ -216,0 +218,0 @@ process.stdout.write(os.EOL) |
@@ -19,3 +19,2 @@ 'use strict' | ||
const CliProgress = require('cli-progress') | ||
const colors = require('colors/safe') | ||
const moment = require('moment') | ||
@@ -32,4 +31,4 @@ /* eslint-disable no-unused-vars */ | ||
const formatter = require('./formatter') | ||
const theme = require('./theme') | ||
/** | ||
@@ -68,3 +67,3 @@ * Timecode format | ||
const baseOptions = { | ||
format: `🎬 ${colors.grey('Rendering')} ${colors.green.bold('{filename}')} ${colors.white.bold('|')} ${colors.blue('{bar}')} ${colors.blue.bold('{percentagePad}%')} ${colors.white.bold('|')} ${colors.grey('ETA')} ${colors.red.bold('{etaTimecode}')}`, | ||
format: `🎬 ${theme.filenameLabel('Rendering')} ${theme.filename('{filename}')} | ${theme.beam('{bar}')} ${theme.percentage('{percentagePad}%')} | ${theme.etaLabel('ETA')} ${theme.eta('{etaTimecode}')}`, | ||
fps: 20, | ||
@@ -71,0 +70,0 @@ barsize: 60, |
{ | ||
"name": "ffmpeg-progressbar-cli", | ||
"version": "1.1.2", | ||
"version": "1.2.2", | ||
"description": "A colored progress bar for FFmpeg. Simply use `ffmpeg-bar` instead of `ffmpeg`.", | ||
@@ -41,4 +41,4 @@ "license": "MIT", | ||
"app-root-path": "^2.1.0", | ||
"chalk": "^2.4.1", | ||
"cli-progress": "git+https://github.com/AndiDittrich/Node.CLI-Progress.git#master", | ||
"colors": "^1.3.1", | ||
"ellipsize": "^0.1.0", | ||
@@ -45,0 +45,0 @@ "ini": "^1.3.5", |
Sorry, the diff of this file is not supported yet
234658
19
780
+ Addedchalk@^2.4.1
+ Addedansi-styles@3.2.1(transitive)
+ Addedchalk@2.4.2(transitive)
+ Addedcolor-convert@1.9.3(transitive)
+ Addedcolor-name@1.1.3(transitive)
+ Addedescape-string-regexp@1.0.5(transitive)
+ Addedhas-flag@3.0.0(transitive)
+ Addedsupports-color@5.5.0(transitive)
- Removedcolors@^1.3.1
- Removedcolors@1.4.0(transitive)