Skip to content

Instantly share code, notes, and snippets.

@furycd001
Last active September 14, 2020 06:53
Show Gist options
  • Save furycd001/d53a9435d5e046737d64884429b945e8 to your computer and use it in GitHub Desktop.
Save furycd001/d53a9435d5e046737d64884429b945e8 to your computer and use it in GitHub Desktop.

Adding a progress bar to GNU Core Utilities copy & move.

Advanced Copy is an awesome mod for GNU Core Utilities that adds a handy progress bar to cp & mv. This can be super helpfully when copying or moving large files or directories, because you'll be able to see how far along the process is.

The install process is extremely simple. Just follow the commands below typing them into a terminal & then logout / log back in to finish..

  • Download GNU Core Utilities....

wget http://ftp.gnu.org/gnu/coreutils/coreutils-8.32.tar.xz

  • Extract the downloaded file & move into the directory....

tar xvJf coreutils-8.32.tar.xz && cd coreutils-8.32/

  • Download the Advanced Copy patch....

wget https://raw.githubusercontent.com/jarun/advcpmv/master/advcpmv-0.8-8.32.patch

  • Apply the patch that you just downloaded....

patch -p1 -i advcpmv-0.8-8.32.patch

  • Compile GNU Core Utilities with the Advanced Copy patch applied....

./configure && make

  • Install the newly compiled cp & mv....

sudo mv ./src/cp /usr/local/bin/cpg && sudo mv ./src/mv /usr/local/bin/mvg

  • Create aliases in your .bashrc or .bash_aliases....

alias cp='cp -gR' >> ~/.bashrc_aliases
alias mv='mv -g' >> ~/.bashrc_aliases

  • Logout and then log back in for everything to start working....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment