Created
April 30, 2021 01:55
-
-
Save barelyhuman/f8b9c15236f0aab8485ab6a9062e1ac8 to your computer and use it in GitHub Desktop.
my zsh base setup
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/zsh | |
if [ ! -d ~/.oh-my-zsh ]; then | |
sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" | |
fi | |
if ! command -v git &> /dev/null | |
then | |
echo "git wasn't found, install it" | |
exit | |
fi | |
mkdir -p "$HOME/.zsh" | |
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions | |
git clone https://github.com/sindresorhus/pure.git "$HOME/.zsh/pure" | |
# setup pure prompt | |
echo "fpath+=('$HOME/.zsh/pure')" >> ~/.zshrc | |
echo "autoload -U promptinit; promptinit" >> ~/.zshrc | |
echo "prompt pure" >> ~/.zshrc | |
sed -i 's/ZSH_THEME="robbyrussell"/ZSH_THEME=""/g' ~/.zshrc | |
# replace plugins to have zsh autosuggestions added | |
sed -i 's/"plugins=("/"plugins=(zsh-autosuggestions "/g' ~/.zshrc | |
echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> ~/.zshrc | |
## setup node | |
curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.38.0/install.sh | bash | |
source ~/.nvm/nvm.sh | |
nvm install 12 | |
nvm install 14 | |
nvm alias default 12 | |
echo "source ~/.nvm/nvm.sh" >> ~/.zshrc |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment