Last active
April 18, 2017 19:33
-
-
Save doublecompile/a6c99bc95ab02389c09f027358327752 to your computer and use it in GitHub Desktop.
Setup my dotfiles
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/sh | |
if [ -n "$(command -v yum)" ]; then | |
sudo yum -y install git | |
elif [ -n "$(command -v apt-get)" ]; then | |
sudo apt-get update | |
sudo apt-get install -y git stow | |
fi | |
pwd=$(pwd) | |
git clone https://github.com/doublecompile/dotfiles.git ~/dotfiles | |
rm ~/.bashrc | |
rm ~/.profile | |
rm ~/.bash_logout | |
cd dotfiles | |
if [ -n "$(command -v stow)" ]; then | |
stow bash | |
else | |
for f in $(find $HOME/dotfiles/bash -type f); do | |
ln -s $f $HOME/$(basename $f) | |
done | |
fi | |
cd $pwd |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment