title |
---|
GIT: .gitconfig |
- Config name and email for git.
- Replace 'cbkadal/Cicak Bin Kadal' with your own name.
- Visit https://github.com/settings/emails{:target="_blank"} For cbkadal, the web-based Git operations email address is "[email protected]"
git config --global user.email '[email protected]'
git config --global user.name 'Cicak Bin Kadal'
git config --global core.editor 'vi'
git config --global credential.helper 'cache --timeout=3600'
git config --global pull.rebase 'true'
git config user.email
git config user.name
git config core.editor
git config credential.helper
git config pull.rebase
sleep 1
git config --list
sleep 1
cat $HOME/.gitconfig
(RESULT)
cbkadal@cbkadal:~$ git config --global user.email '[email protected]'
cbkadal@cbkadal:~$ git config --global user.name 'Cicak Bin Kadal'
cbkadal@cbkadal:~$ git config --global core.editor 'vi'
cbkadal@cbkadal:~$ git config --global credential.helper 'cache --timeout=3600'
cbkadal@cbkadal:~$ git config --global pull.rebase 'true'
cbkadal@cbkadal:~$ git config user.email
[email protected]
cbkadal@cbkadal:~$ git config user.name
Cicak Bin Kadal
cbkadal@cbkadal:~$ git config core.editor
vi
cbkadal@cbkadal:~$ git config credential.helper
cache --timeout=3600
cbkadal@cbkadal:~$ git config pull.rebase
false
cbkadal@cbkadal:~$ sleep 1
cbkadal@cbkadal:~$ git config --list
[email protected]
user.name=Cicak Bin Kadal
core.editor=vi
credential.helper=cache --timeout=3600
pull.rebase=true
cbkadal@cbkadal:~$ sleep 1
cbkadal@cbkadal:~$ cat $HOME/.gitconfig
[user]
email = [email protected]
name = Cicak Bin Kadal
[core]
editor = vi
[credential]
helper = cache --timeout=3600
[pull]
rebase = true
cbkadal@cbkadal:~$
## rebase: true or false?
- The recommended value of "pull.rebase" is "true"
- However --- if you wish --- you might want to switch it to "false"
git config --global pull.rebase 'false'
git config pull.rebase
## Default Branch: master?
- To set default branch as master:
git config --global init.defaultBranch master
git config init.defaultBranch