forked from grifflug/dotfiles
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
executable file
·47 lines (36 loc) · 1.17 KB
/
Copy pathinstall.sh
File metadata and controls
executable file
·47 lines (36 loc) · 1.17 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
46
47
#!/bin/bash
DOTFILES=$HOME/.dotfiles
PRIVATE=$DOTFILES/private
DEFAULTSUBREPO="git@github.com:grifflug/private.git"
if [ -d "$PRIVATE" ]; then
rm -Rf $PRIVATE;
fi
#Make this create and fill in the .profile file.
# echo "What is your default User: "
# read input_variable
# echo "You entered: $input_variable";
echo "Please enter the address to your git that has your settings: "
read gitRepo_variable
echo "You entered: $gitRepo_variable";
#this needs to be changed to submodule?
#Though there is a problem of changing the remote ref a submodule that is already
#been added. Help.
if [[ -z "$gitRepo_variable" ]]; then
git clone $DEFAULTSUBREPO private;
cd $PRIVATE;
git remote rm origin
cd $DOTFILES;
else
git clone $gitRepo_variable private;
fi;
#install git comletion
curl https://gist.githubusercontent.com/jahead/9578308/raw/install-git-completion.sh -OL
source $DOTFILES/install-git-completion.sh
rm $DOTFILES/install-git-completion.sh
# Make sure everything is up-to-date
unlink ~/.bash_profile;
unlink ~/.bashrc;
unlink ~/.gitconfig;
link $DOTFILES/.bash_profile ~/.bash_profile;
link $DOTFILES/.bashrc ~/.bashrc;
link $DOTFILES/.gitconfig ~/.gitconfig;