Skip to content

Instantly share code, notes, and snippets.

@howie
Last active September 10, 2023 10:06
Show Gist options
  • Save howie/f05ed791b26753be24beb7b028cc8624 to your computer and use it in GitHub Desktop.
Save howie/f05ed791b26753be24beb7b028cc8624 to your computer and use it in GitHub Desktop.
Install YARD dotfile
#!/bin/bash
set -e
#
# Install YARD dotfile
#
#
sh -c "`curl -fsSL https://raw.githubusercontent.com/skwp/dotfiles/master/install.sh`"
#
# 安裝 agnoster.zsh-theme
# http://rocket-science.ru/shell/2013/04/04/yadr-for-dummies/
#
if [ ! -d "$HOME/.zsh.prompts" ]; then
echo "Create zsh prompts...."
mkdir $HOME/.zsh.prompts
wget https://gist.githubusercontent.com/agnoster/3712874/raw/c3107c06c04fb42b0ca27b0a81b15854819969c6/agnoster.zsh-theme
mv agnoster.zsh-theme ~/.zsh.prompts/prompt_agnoster_setup
else
echo "zsh.prompts is already installed"
fi
if [[ -f "$HOME/.yadr/zsh/get-short-path.zsh" ]]; then
echo "get-short-path.zsh is already installed"
else
wget https://gist.githubusercontent.com/howie/b7bec91e4af9f3b679b7e1d36eea8e49/raw/get-short-path.zsh -O $HOME/.yadr/zsh/get-short-path.zsh
fi
if [[ ! -f "$HOME/.yadr/zsh/git-omz.zsh" ]]; then
wget https://gist.githubusercontent.com/howie/ffc444e946eb0fe70a198be9caac324b/raw/git-omz.zsh -O $HOME/.yadr/zsh/git-omz.zsh
else
echo "git-omz.zsh is already installed"
fi
#font
brew tap homebrew/cask-fonts
brew install --cask font-source-code-pro
brew install --cask font-fontawesome
brew install --cask font-inconsolata-dz-for-powerline
brew install --cask font-menlo-for-powerline
#
# Download font, but need manual install
#
#wget https://gist.githubusercontent.com/qrush/1595572/raw/2eb22321d590265799aac5b166cd19f8358b0db1/mensch-Powerline.otf
#open mensch-Powerline.otf
if ! grep -q "autoload -Uz promptinit" $HOME/.zshrc; then
echo "autoload -Uz promptinit" >> $HOME/.zshrc
echo "promptinit " >> $HOME/.zshrc
echo "prompt agnoster" >> $HOME/.zshrc
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment