#!/bin/bash # # Download Go, verify its signature, and if that all succeeds, move the tarball # to go.tar.gz in the current directory. set -eu if [ $# -eq 0 ]; then echo "usage: $0 [platform like linux-amd64]" exit 1 fi VERSION="${1}" PLATFORM="${2:-linux-amd64}" export GNUPGHOME="$(mktemp -d)" # From https://www.google.com/linuxrepositories/ # # Key Details # Download: https://dl.google.com/linux/linux_signing_key.pub # Key ID: Google, Inc. Linux Package Signing Key # Fingerprint: 4CCA 1EAF 950C EE4A B839 76DC A040 830F 7FAC 5991 # Google, Inc. (Linux Package Signing Authority) # Fingerprint: EB4C 1BFD 4F04 2F6D DDCC EC91 7721 F63B D38B 4796 gpg2 --import <