-
-
Save fourside/ef69da72c47779591ee9ab23af096ea4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -ex | |
cd ~/work | |
GH_URL=`gh release view -R cli/cli --json assets -q .assets[].url | grep linux_amd64.tar.gz` | |
curl -LO $GH_URL | |
GH_FILE=`basename ${GH_URL}` | |
tar xzf $GH_FILE | |
GH_DIR=${GH_FILE%.tar.gz} | |
ln -fs ~/work/${GH_DIR}/bin/gh ~/bin/gh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment