# GIT
### Remote
Xem danh sách các remote
`git remote -v`
`git remote add {tên remote mặc định là origin} {url}`
`git remote set-url {tên remote mặc định là origin} {url}`
### Fetch
Fetch là lấy từ remote về nhưng không tự động ghép vào nhánh
`git fetch `{tên remote mặc định là origin} {tên nhánh}` hoac `--all`: get tất cả}
### Pull
Giống fetch nhưng ráp code mới vào working dir
`git pull {tên remote mặc định là origin} {tên nhánh}`
### Push
Đẩy code lên remote
`git push {tên remote mặc định là origin} {tên nhánh}` neu nhanh hien tthi HEAD thay cho ten nhanh.
### xoa bo cc thay doi
```
git reset --hard
```