Skip to content

Instantly share code, notes, and snippets.

@JohnAZoidberg
Created June 29, 2017 15:16
Show Gist options
  • Save JohnAZoidberg/b546b3fd04b676918ba398055c90f799 to your computer and use it in GitHub Desktop.
Save JohnAZoidberg/b546b3fd04b676918ba398055c90f799 to your computer and use it in GitHub Desktop.
Log shell output to colored html
BUFFER="log.txt"
LOGGER=$1
OUTPUT=$2
while inotifywait -e modify log.txt; do $(cat $BUFFER | aha --black > $OUTPUT); done &
echo "---------------------------Restart---------------------------" >> $BUFFER
unbuffer $LOGGER >> $BUFFER
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment