File tree 2 files changed +9
-0
lines changed
2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -171,6 +171,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`.
171
171
* [ List all git aliases] ( #list-all-git-aliases )
172
172
* [ Show git status short] ( #show-git-status-short )
173
173
* [ Checkout a commit prior to a day ago] ( #checkout-a-commit-prior-to-a-day-ago )
174
+ * [ Push the current branch to the same name on the remote repository] ( #push-the-current-branch-to-the-same-name-on-the-remote-repository )
174
175
* [ Push a new local branch to remote repository and track] ( #push-a-new-local-branch-to-remote-repository-and-track )
175
176
* [ Change a branch base] ( #change-a-branch-base )
176
177
* [ Use SSH instead of HTTPs for remotes] ( #use-ssh-instead-of-https-for-remotes )
@@ -1223,6 +1224,11 @@ git status --short --branch
1223
1224
git checkout master@{yesterday}
1224
1225
```
1225
1226
1227
+ ## Push the current branch to the same name on the remote repository
1228
+ ```sh
1229
+ git push origin HEAD
1230
+ ```
1231
+
1226
1232
## Push a new local branch to remote repository and track
1227
1233
```sh
1228
1234
git push -u origin <branch_name>
Original file line number Diff line number Diff line change 511
511
"title" : " Checkout a commit prior to a day ago" ,
512
512
"tip" : " git checkout master@{yesterday}"
513
513
}, {
514
+ "title" : " Push the current branch to the same name on the remote repository" ,
515
+ "tip" : " git push origin HEAD"
516
+ }, {
514
517
"title" : " Push a new local branch to remote repository and track" ,
515
518
"tip" : " git push -u origin <branch_name>"
516
519
}, {
You can’t perform that action at this time.
0 commit comments