-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·45 lines (38 loc) · 1.02 KB
/
install.sh
File metadata and controls
executable file
·45 lines (38 loc) · 1.02 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/bin/bash
function place_files() {
git clone "https://github.com/astropuffin/dotfiles.git"
for file in .tmux.conf .vimrc .zcompdump .bashrc .zshrc .vim .gitconfig
do
cp -r "dotfiles/$file" ~
done
}
function setup_git() {
git config --global push.default simple
git config --global user.name=astropuffin
git config --global user.email=astropuffin@users.noreply.github.com
}
function vim-pathogen(){
mkdir -p ~/.vim/autoload ~/.vim/bundle && \
curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim
pushd ~/.vim/bundle
git clone https://github.com/hashivim/vim-terraform.git
popd
}
function cleanup(){
rm -rf dotfiles
rm install.sh
}
#install packages
if [ $(which apt-get | wc -l) -eq 1 ]; then
echo "installing pachages via apt-get. Will require sudo password"
sudo apt-get install -y vim git keychain tmux zsh
else
echo "not ubuntu, and RH family not handled by this script"
cleanup
exit 1
fi
place_files
setup_git
vim-pathogen
cleanup
source ~/.bashrc