Introduction to Git
git --version
git help config
clear
git config --global user.name "Nasrul"
git config --global user.email "nasrulhazim.m@gmail.com"
git init
ls
ls -la
touch [file name]
git add [file/folder]
git add *
git add *.php
git commit -m "your message here"
git log
git log --pretty=oneline
git rm [files/folder]
git commit -m "removed [files/folders]"
** add -r for delete recursively for directory
RULES: FILES / FOLDERS STATUS MUST BE MODIFIED
git commit -a -m "add and commit only for modified files"
create .gitignore
- specific file [filename]
- wildcard *
- exception (!)
git clone [remote-server] [folder-name]
//initiliazed repo
git init
git remote add [alias] [url]
git pull [alias-remote-server] [branch-name]
git branch [branch-name]
git push [alias-remote-server] [branch-name]