Skip to content

Instantly share code, notes, and snippets.

@mckeed
Created October 15, 2015 15:45
Show Gist options
  • Save mckeed/4f7b7545e5c2be71d468 to your computer and use it in GitHub Desktop.
Save mckeed/4f7b7545e5c2be71d468 to your computer and use it in GitHub Desktop.
Shell script for easy encrypting of folders using keybase (I'm not a shell script master so let me know if there's errors)
if [ -d "$2" ]; then
( set -x
tar -cz "$2" | keybase encrypt -bs $1 -o "$2".tgz.gpg
)
elif [ -f "$2" ]; then
( set -x
keybase encrypt -bs $1 $2
)
else
echo "Usage: encrypto keybaseuser path"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment