README.md added
This commit is contained in:
parent
004f18c287
commit
7c285cfdc3
22
README.md
Normal file
22
README.md
Normal file
@ -0,0 +1,22 @@
|
||||
|
||||
For advanced git commands training
|
||||
|
||||
You can make any training in test branch
|
||||
|
||||
## git reset
|
||||
To make a commit you need to do 3 steps:
|
||||
1. Make changes
|
||||
2. Add them to staging area
|
||||
3. Make a commit
|
||||
|
||||
```
|
||||
git reset --soft # resets #3 only
|
||||
git reset (--mixed) # resets #3 and #2
|
||||
git reset --hard # resets all #3, #2 and #1
|
||||
```
|
||||
## git rebase
|
||||
```
|
||||
git rebase <hash> # rebase using commits's hash
|
||||
git rebase -i HEAD~n # interactive rebase for last n commits
|
||||
```
|
||||
|
Loading…
x
Reference in New Issue
Block a user