Tested on Ubuntu 18.04

This script adds an SSH key to the server for the current user.

It prompts the current user for the public SSH key contents.

Usage:

bash <(curl -sSL https://jrussell.sh/add-ssh-key)

Raw Script Contents