nwronski / batch-transcode-video

Batch transcode videos using the video_transcoding gem
MIT License
43 stars 8 forks source link

Report progress in terminal title bar #9

Open sadlerjw opened 6 years ago

sadlerjw commented 6 years ago

Some terminals (like ConEmu on Windows) can report progress in their UIs (or in the task bar) if the terminal title is set properly. See https://github.com/Maximus5/ConEmu/issues/1329#issuecomment-346501505

Looks like it should be pretty easy to do:

// from https://stackoverflow.com/a/30360821
function setTerminalTitle(title)
{
  process.stdout.write(
    String.fromCharCode(27) + "]0;" + title + String.fromCharCode(7)
  );
}

This repo is a pretty cool addition to the transcoding workflow. Thanks for creating it!