Skip to content

Instantly share code, notes, and snippets.

@lisamelton
Created July 5, 2018 15:55
Show Gist options
  • Save lisamelton/f0c218be392bf8ad49b75737870c9473 to your computer and use it in GitHub Desktop.
Save lisamelton/f0c218be392bf8ad49b75737870c9473 to your computer and use it in GitHub Desktop.
A script to filter out overwritten `HandBrakeCLI` progress information from a `.log` file created `transcode-video`.
#!/bin/bash
#
# prune-handbrake-log.sh
#
# Copyright (c) 2018 Don Melton
#
if (($# == 1)); then
cat "$1" | ruby -e "print STDIN.read.gsub(/^.*\r(.)/, '\1')"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment