Skip to content

Instantly share code, notes, and snippets.

@KevinBatdorf
Last active August 12, 2018 12:42
Show Gist options
  • Save KevinBatdorf/f91cf59e4d0582ee685e9dbbb928c973 to your computer and use it in GitHub Desktop.
Save KevinBatdorf/f91cf59e4d0582ee685e9dbbb928c973 to your computer and use it in GitHub Desktop.
Homestead after.sh Win10
#!/bin/sh
# If you would like to do some extra provisioning you may
# add any commands you wish to this file and they will
# be run after the Homestead machine is provisioned.
if [ ! -f /usr/local/extra_homestead_software_installed ]; then
echo 'installing some extra software'
#
# install zsh
#
sudo apt-get install zsh -y
#
# install oh my zhs
# (after.sh is run as the root user, but ssh is the vagrant user)
#
git clone git://github.com/robbyrussell/oh-my-zsh.git /home/vagrant/.oh-my-zsh
cp /home/vagrant/.oh-my-zsh/templates/zshrc.zsh-template /home/vagrant/.zshrc
sudo chsh -s /usr/bin/zsh vagrant
#
# Install some extras
#
git clone https://github.com/zsh-users/zsh-autosuggestions /home/vagrant/.oh-my-zsh/custom/plugins/zsh-autosuggestions
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git /home/vagrant/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting
#
# use .dotfiles from osx
#
sudo rm -f /home/vagrant/.zshrc
sudo ln -s /home/vagrant/code/.zshrc /home/vagrant/.zshrc
sudo ln -s /home/vagrant/code/.bashrc /home/vagrant/.bashrc_2
sudo ln -s /home/vagrant/code/.bash_profile /home/vagrant/.bash_profile
sudo echo "source ./.bashrc_s" >> /home/vagrant/.bashrc
#
# make tab complete case insensitive
#
sudo echo set completion-ignore-case on | sudo tee -a /etc/inputrc
#
# set up global gitignore
#
git config --global core.excludesfile ~/.gitignore_global
sudo echo ".DS_Store" > ~/.gitignore_global
#
# install java
#
# sudo apt-get install default-jre-headless
#
# install httpie
#
sudo apt-get install httpie
#
# remember that the extra software is installed
#
sudo touch /usr/local/extra_homestead_software_installed
else
echo "extra software already installed... moving on..."
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment