#!/bin/bash path="/path/to/local/output/file.txt" bitcoin="" datetime=$(date "+%d-%b-%Y") host="canary.example.com" user="sftp_username" remotepath="/home/sftp_username"; myname="Name" # Get the current bitcoin hash echo "Enter most recent Bitcoin hash (https://bitref.com/block):" read bitcoin cat >$path.tmp <