Git: Difference between revisions
No edit summary |
No edit summary |
||
Line 31: | Line 31: | ||
git add (whatever you want to track) | git add (whatever you want to track) | ||
git commit -a -m "init repo" && git push | git commit -a -m "init repo" && git push | ||
|} | |||
{| class="mw-collapsible mw-collapsed wikitable" | |||
! Set default branch of a bare repo | |||
|- | |||
| If you want the default branch of a bare repo to be something other than master: | |||
🌵 m@bitpost [~/development/Libraries/c++/Simple-Web-Server.git] git branch | |||
* master | |||
moodboom-quick-http | |||
🌵 m@bitpost [~/development/Libraries/c++/Simple-Web-Server.git] git symbolic-ref HEAD refs/heads/moodboom-quick-http | |||
🌵 m@bitpost [~/development/Libraries/c++/Simple-Web-Server.git] git branch | |||
master | |||
* moodboom-quick-http | |||
|} | |} | ||
{| class="mw-collapsible mw-collapsed wikitable" | {| class="mw-collapsible mw-collapsed wikitable" |
Revision as of 07:34, 28 June 2019
TASKS
Expandgit new shared central bare repo |
---|
Expandcreate shared central repo for existing code |
---|
ExpandSet default branch of a bare repo |
---|
Expandgit merging conflicts after diverging |
---|
Expandgit create and push a feature branch |
---|
Expandgetting upstream commits into your GitHub fork |
---|
Expandgit create new branch on server, pull to client |
---|
Expandgit remove old branches |
---|
ExpandWork with two local repos |
---|
Expandgit pull when untracked files are in the way |
---|
Expandgit create new branch when untracked files are in the way |
---|
Expandgit recreate repo |
---|
Expandgit connect to origin after the fact |
---|
Expandgit ignore local and remote changes to a file |
---|
Expandgit branch rebase to keep master intact |
---|
Expandgit changing branches in a project with submodules |
---|
Expandgit hard-reset a misbehaving submodule to parent commit version |
---|
CONFIGURATION
Expandgit visual difftool and mergetool setup |
---|
Expandgit convert to a bare repo |
---|
Expandgit convert bare to a mirror of remote (github, facebook, etc) |
---|
Expandgit create merge-to command |
---|
Expandgit fix github diverge from local bare repo following README.md edit |
---|
Expandgit windows configure notepad++ editor |
---|
Expandgit fix push behavior - ONLY PUSH CURRENT doh |
---|
Expandgit multiple upstreams |
---|
From here...