Skip to content

Instantly share code, notes, and snippets.

@AlecZadikian9001
Created April 25, 2018 18:49
Show Gist options
  • Save AlecZadikian9001/909789bcca957615f1e933c5c8122a48 to your computer and use it in GitHub Desktop.
Save AlecZadikian9001/909789bcca957615f1e933c5c8122a48 to your computer and use it in GitHub Desktop.
File copy shell script that shows progress
# Tested in Ubuntu 14, requires pv
copy ()
{
echo Copying $1 to $2
cat $1 | pv -a -r -b -p -e -s $(stat --printf="%s" $1) > $2
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment