-
-
Save SpenserJ/5001775 to your computer and use it in GitHub Desktop.
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/bash -ex | |
# Paste this into ssh | |
# curl -sL https://gist.github.com/gists/5001775/download | tar -xzO | /bin/bash -ex | |
# When forking, you can get the URL from the download button. | |
pushd $HOME | |
aptget='sudo apt-get' | |
chsh='sudo chsh' | |
if [ `whoami` = 'root' ]; then | |
aptget='apt-get' | |
chsh='chsh' | |
fi | |
### Dependencies ### | |
$aptget update | |
$aptget install -y zsh tmux vim git | |
curl -s https://raw.github.com/andsens/homeshick/master/install.sh | bash | |
### Trust github ### | |
mkdir -p .ssh | |
cat <<EOF >> .ssh/known_hosts | |
|1|6WX8FDwncDK8tfyfkLLbvyepVRw=|15RHFpHg3GHML7eJqvNL/yVYChI= ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ== | |
|1|cccEMXs7ur0u/JXs4NQYv4A9Xb8=|Pddv+wa776NKeZ4v1yMn1cZWt4s= ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEAq2A7hRGmdnm9tUDbO9IDSwBK6TbQa+PXYPCPy6rbTrTtw7PHkccKrpp0yVhp5HdEIcKr6pLlVDBfOLX9QUsyCOV0wzfjIJNlGEYsdlLJizHhbn2mUjvSAHQqZETYP81eFzLQNnPHt4EVVUh7VfDESU84KezmD5QlWpXLmvU31/yMf+Se8xhHTvKSCZIFImWwoG6mbUoWf9nzpIoaSjB+weqqUUmpaaasXVal72J+UX2B+2RPW3RcT0eOzQgqlJL3RKrTJvdsjE3JEAvGq3lGHSZXy28G3skua2SmVi/w4yCE6gbODqnTWlg7+wC604ydGXA8VJiS5ap43JXiUFFAaQ== | |
EOF | |
$HOME/.homeshick clone git@github.com:SpenserJ/dotfiles.git | |
mkdir symlink-backup | |
mv .bashrc symlink-backup/ || true | |
mv .profile symlink-backup/ || true | |
$HOME/.homeshick symlink dotfiles | |
printf '\nalias homesick="$HOME/.homeshick"' >> .bashrc | |
popd | |
chsh --shell /bin/zsh `whoami` | |
echo "Log in again to start your proper shell" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment