Common git operations » History » Version 3
Version 2 (cryptogopher, 2019-05-09 23:59) → Version 3/18 (cryptogopher, 2019-05-10 00:00)
h1. Common git operations
Prerequisites:
<pre>
cd ~/plugins/issue_recurring
</pre>
h2. Issue resolution in separate branch
h3. Create separate branch for issue
# Checkout and update master:
<pre>
$ git checkout master
$ git pull
</pre>
# Create, checkout new branch and push it to remote (so it will be tracked and replicated on it.michalczyk.pro):
<pre>
$ git checkout -b issueN
$ git push -u origin issueN
</pre>
h3. Merge issue branch into master
# Push uncommited changes on issue branch.
# Checkout and update master:
<pre>
$ git checkout master
$ git pull
</pre>
# Merge and push issueN branch:
<pre>
$ git merge issueN
$ git push
</pre>
# Delete merged branch from local and remote:
<pre>
$ git branch -d issueN
$ git push origin :issueN
</pre>
# Verify:
<pre>
$ git branch -a
</pre>
Prerequisites:
<pre>
cd ~/plugins/issue_recurring
</pre>
h2. Issue resolution in separate branch
h3. Create separate branch for issue
# Checkout and update master:
<pre>
$ git checkout master
$ git pull
</pre>
# Create, checkout new branch and push it to remote (so it will be tracked and replicated on it.michalczyk.pro):
<pre>
$ git checkout -b issueN
$ git push -u origin issueN
</pre>
h3. Merge issue branch into master
# Push uncommited changes on issue branch.
# Checkout and update master:
<pre>
$ git checkout master
$ git pull
</pre>
# Merge and push issueN branch:
<pre>
$ git merge issueN
$ git push
</pre>
# Delete merged branch from local and remote:
<pre>
$ git branch -d issueN
$ git push origin :issueN
</pre>
# Verify:
<pre>
$ git branch -a
</pre>