21 lines
740 B
Bash
21 lines
740 B
Bash
#!/bin/sh
|
|
|
|
# Check if git installed
|
|
if ! command -v git &> /dev/null; then
|
|
echo "This script requires git"
|
|
exit 1
|
|
fi
|
|
|
|
# Asking if user really want to install
|
|
read -p 'This script will install oh my zsh and replace .zshrc with its own. If you still want to run it, type "y": ' -n 1 -r
|
|
echo
|
|
if [[ ! $REPLY =~ ^[Yy]$ ]]; then
|
|
exit 1
|
|
fi
|
|
|
|
# Installing
|
|
set -x
|
|
wget -O ~/.zshrc https://nakidai.ddns.net/nakidai/dotfiles/raw/branch/master/zsh/.zshrc
|
|
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
|
|
wget -O ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/themes/headline.zsh-theme https://nakidai.ddns.net/nakidai/dotfiles/raw/branch/master/zsh/headline.zsh-theme
|