#!/usr/bin/env bash # Installs oh-my-zsh on GCP Cloud Shell in a single command. # Run this script directly from the command line # # $ curl "https://gist.githubusercontent.com/dzuluaga/3bf775217728debf360a4377c7eb5118/raw/install-oh-my-zsh-gcp-cloud-shell.sh?$(date +%s)" | sudo bash # .---------- constant part! # vvvv vvvv-- the code from above RED='\033[0;31m' NC='\033[0m' # No Color printf "I ${RED}love${NC} Stack Overflow\n" echo 'Installin zsh...' sudo apt-get -yq install zsh echo 'Downloading and installing oh-my-zsh' sudo sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" echo echo "Next Steps" echo printf "Remember to start zsh by running everytime you start Cloud Shell ${RED}$ zsh${NC}" echo printf "Remember to edit ${RED}~/.zshrc${NC} with this line to enable some useful plugins" echo printf "${RED}plugins=(vi-mode git git-flow rails textmate ruby cap brew gem github mysql osx vagrant jsontools zsh-syntax-highlighting history-substring-search){NC}" echo