Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Install the latest static tmate and start a session
TMATE_FILE=$($(command -v python3 || command -v python) <<EOC
import requests
r = requests.get(
releases = r.json()
amd64_releases = [
i for i in releases['assets']
if 'amd64' in i['name'] and not 'dbg' in i['name']
r = requests.get(amd64_releases['browser_download_url'], allow_redirects=True)
with open(amd64_releases['name'], 'wb') as f:
tar xf ${TMATE_FILE}
sudo cp $(basename -s '.tar.xz' ${TMATE_FILE})/tmate /usr/local/bin/
echo "tmate-io has been installed. To use tmate, execute the tmate command normally."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment