Created
February 17, 2018 01:33
-
-
Save NZSmartie/58b1598ea6c006de441df03ba88ff14e to your computer and use it in GitHub Desktop.
Becausse Go doesn't support command aliasing... 🤬
This file contains hidden or 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
# TODO: Get latest release, not aa fixed version | |
sudo wget https://github.com/golang/dep/releases/download/v0.4.1/dep-linux-amd64 -O /usr/bin/go-dep | |
sudo chmod u=rwx,go=rx /usr/bin/go-dep | |
cat > $HOME/.bashrc <<EOL | |
# Alias 'go dep' to go-dep | |
go() { | |
if [[ $@ == dep\ * ]]; then | |
command go-dep $(echo "$@" | cut -c 5-) | |
else | |
command go "$@" | |
fi | |
} | |
EOL | |
# To take affect, log out and log in. or type `source ~/.bashrc` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment