Created
October 24, 2021 18:39
-
-
Save basilmusa/37ec89ab360e9aa9500f632fa8df0772 to your computer and use it in GitHub Desktop.
Revisions
-
basilmusa created this gist
Oct 24, 2021 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,18 @@ #!/bin/bash if [[ $EUID -ne 0 ]]; then echo "*** This script must be run as root ***" exit 1 fi if hash restic 2>/dev/null; then echo "*** restic is already installed ***"; restic version exit 0; fi cd /usr/local/bin wget https://github.com/restic/restic/releases/download/v0.12.1/restic_0.12.1_linux_amd64.bz2 -q -O restic.bz2 bunzip2 restic.bz2 chmod +x restic restic generate --bash-completion /etc/bash_completion.d/restic cd $OLDPWD