#!/bin/sh
DIR=$(dirname $0)

# install vimplug
curl -fLo ~/.vim/autoload/plug.vim --create-dirs \
    https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim

# install oh-my-zsh
sh -c "$(wget https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)"

# install zsh plugins
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

mkdir -p ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/themes

git clone https://github.com/ergenekonyigit/lambda-gitster.git
cp lambda-gitster/*.zsh-theme ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/themes

# symlinks
ln -s $DIR/.vimrc ~/.vimrc
ln -s $DIR/.ideavimrc ~/.ideavimrc
ln -s $DIR/.gitconfig ~/.gitconfig
ln -s $DIR/.zshrc ~/.zshrc
ln -s $DIR/.Xdefaults ~/.Xdefaults

ln -s $DIR/awesome/ ~/.config/awesome/
