Skip to content

Instantly share code, notes, and snippets.

@yinkar
Created October 25, 2021 08:53
Show Gist options
  • Save yinkar/b4190d92d880c3f6e434606691ea81ca to your computer and use it in GitHub Desktop.
Save yinkar/b4190d92d880c3f6e434606691ea81ca to your computer and use it in GitHub Desktop.
watch.sh
#!/bin/bash
buff=$( cat "$1" )
while :
do
if [ "$( cat "$1" )" != "$buff" ]; then
cat "$1"
echo -e "\r\n"
buff=$( cat "$1" )
fi
sleep 1
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment