-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup.sh
More file actions
32 lines (29 loc) · 687 Bytes
/
Copy pathsetup.sh
File metadata and controls
32 lines (29 loc) · 687 Bytes
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
#!/bin/bash
out=$(git)
if [ $? == 0 ]
then
echo "Please install git first!"
exit
fi
echo "Please enter a name:"
read name
echo "please enter an email address:"
read email
out=$(git config --global user.name "$name")
out=$(git config --global user.email "$email")
echo "Would you like to cache your username and password?(y/n)"
read yn
if [ "$yn" = "y" ]
then
out=$(git config --global credential.helper 'cache --timeout=3600')
fi
echo "Would you like to set your default editor?(y/n)"
read yn
if [ "$yn" = "y" ]
then
echo "Please enter your default editor:(emacs,vim,nano, etc..)"
read editor
out=$(git config --global core.editor $editor)
fi
echo "All Done!"
git config --list