From 974505558f0b922cace0d95b0537b3c577d928ee Mon Sep 17 00:00:00 2001 From: Richard Littauer Date: Mon, 16 Mar 2015 13:18:19 -0700 Subject: [PATCH] Doctoc fixes. :| --- README.md | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index ec7057f..69ce640 100644 --- a/README.md +++ b/README.md @@ -19,13 +19,25 @@ For clarity's sake all examples in this document use customized bash prompt in o **Table of Contents** *generated with [DocToc](https://github.com/thlorenz/doctoc)* - - [I wrote the wrong thing in a commit message](#i-wrote-the-wrong-thing-in-a-commit-message) - - [I need to add staged changes to the previous commit](#i-need-to-add-staged-changes-to-the-previous-commit) - - [I tried to push my amended commit to a remote, but I got an error message](#i-tried-to-push-my-amended-commit-to-a-remote-but-i-got-an-error-message) - - [I need to combine commits](#i-need-to-combine-commits) - - [Possible issues with merging](#possible-issues-with-merging) - - [Safe merging strategy:](#safe-merging-strategy) -- [some code](#some-code) +- [I wrote the wrong thing in a commit message](#i-wrote-the-wrong-thing-in-a-commit-message) +- [I need to add staged changes to the previous commit](#i-need-to-add-staged-changes-to-the-previous-commit) + - [I tried to push my amended commit to a remote, but I got an error message](#i-tried-to-push-my-amended-commit-to-a-remote-but-i-got-an-error-message) +- [I need to combine commits](#i-need-to-combine-commits) + - [Possible issues with merging](#possible-issues-with-merging) + - [Safe merging strategy:](#safe-merging-strategy) + - [I need to merge a branch into a single commit](#i-need-to-merge-a-branch-into-a-single-commit) + - [I want to combine only unpushed commits](#i-want-to-combine-only-unpushed-commits) + - [Possible issues with interactive rebases](#possible-issues-with-interactive-rebases) + - [The rebase editing screen says 'noop'](#the-rebase-editing-screen-says-noop) + - [There were conflicts](#there-were-conflicts) + - [When I try to push, I get an error message:](#when-i-try-to-push-i-get-an-error-message) +- [I committed with the wrong name and email configured](#i-committed-with-the-wrong-name-and-email-configured) +- [I committed to master instead of a new branch](#i-committed-to-master-instead-of-a-new-branch) +- [I made several commits on a single branch that should be on different branches](#i-made-several-commits-on-a-single-branch-that-should-be-on-different-branches) +- [I want to delete local branches that were deleted upstream](#i-want-to-delete-local-branches-that-were-deleted-upstream) +- [I accidentally deleted my branch](#i-accidentally-deleted-my-branch) +- [I want to add aliases for some git commands](#i-want-to-add-aliases-for-some-git-commands) +- [I pulled from/into the wrong branch](#i-pulled-frominto-the-wrong-branch) @@ -134,7 +146,7 @@ If everything is successful, you should see something like this: ``` ### Possible issues with merging #### Safe merging strategy: -```--no-commit``` performs the merge but pretends the merge failed and does not autocommit, giving the user a chance to inspect and further tweak the merge result before committing. ```no-ff``` maintains evidence that a feature branch once existed, keeping project history consistent. +`--no-commit` performs the merge but pretends the merge failed and does not autocommit, giving the user a chance to inspect and further tweak the merge result before committing. `no-ff` maintains evidence that a feature branch once existed, keeping project history consistent. ```sh (master)$ git merge --no-ff --no-commit featurebranch @@ -191,12 +203,11 @@ Changes not staged for commit: In this example, `README.md` has conflicts. Open that file and look for the following: ``` -<<<<<<< HEAD -some code -========= -some code ->>>>>>> new-commit - + <<<<<<< HEAD + some code + ========= + some code + >>>>>>> new-commit ``` You will need to resolve the differences between the code that was added in your new commit (in the example, everything from the middle line to `new-commit`) and your `HEAD`.