Skip to content

Instantly share code, notes, and snippets.

@josuecau
Created August 17, 2017 08:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save josuecau/0228e992d5eabaa3b32126e6e5cc286a to your computer and use it in GitHub Desktop.
Save josuecau/0228e992d5eabaa3b32126e6e5cc286a to your computer and use it in GitHub Desktop.
#!/usr/bin/env bash
#
# Install rclone(1) binary
# More info: https://rclone.org/install/
set -e
echo 'Downloading archive…'
wget -q -O /tmp/rclone-current-linux-amd64.zip \
https://downloads.rclone.org/rclone-current-linux-amd64.zip
echo 'Unpacking archive…'
unzip -qq /tmp/rclone-current-linux-amd64.zip -d /tmp
echo 'Installing binary…'
sudo cp /tmp/rclone-*-linux-amd64/rclone /usr/local/bin
echo 'Installing man page…'
sudo cp /tmp/rclone-*-linux-amd64/rclone.1 /usr/local/share/man/man1
echo 'Updating man pages…'
sudo mandb -q
echo 'Deleting temporary files…'
rm -rf /tmp/rclone-*-linux-amd64*
echo "$(/usr/local/bin/rclone --version) installed."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment