| OLD | NEW |
| 1 # Git Tips | 1 # Git Tips |
| 2 | 2 |
| 3 When using Git, there are a few tips that are particularly useful when working | 3 When using Git, there are a few tips that are particularly useful when working |
| 4 on the Chromium codebase, especially due to its size. | 4 on the Chromium codebase, especially due to its size. |
| 5 | 5 |
| 6 [TOC] | 6 [TOC] |
| 7 | 7 |
| 8 ## Remember the basic git convention: | 8 ## Remember the basic git convention: |
| 9 | 9 |
| 10 git COMMAND [FLAGS] [ARGUMENTS] | 10 git COMMAND [FLAGS] [ARGUMENTS] |
| 11 | 11 |
| 12 Various git commands have underlying executable with a hyphenated name, such as | 12 Various git commands have underlying executable with a hyphenated name, such as |
| 13 `git-grep`, but these can also be called via the `git` wrapper script as | 13 `git-grep`, but these can also be called via the `git` wrapper script as |
| 14 `git grep` (and `man` should work either way too). | 14 `git grep` (and `man` should work either way too). |
| 15 | 15 |
| 16 ## Git references | 16 ## Git references |
| 17 | 17 |
| 18 The following resources can provide background on how Git works: | 18 The following resources can provide background on how Git works: |
| 19 | 19 |
| 20 * [Git-SVN Crash Course](http://git-scm.com/course/svn.html) -- this crash | 20 * [Git-SVN Crash Course](http://git-scm.com/course/svn.html) -- this crash |
| 21 course is useful for Subversion users witching to Git. | 21 course is useful for Subversion users switching to Git. |
| 22 * [Think Like (a) Git](http://think-like-a-git.net/) -- does a great job of | 22 * [Think Like (a) Git](http://think-like-a-git.net/) -- does a great job of |
| 23 explaining the main purpose of Git operations. | 23 explaining the main purpose of Git operations. |
| 24 * [Git User's Manual](http://schacon.github.com/git/user-manual.html) -- a | 24 * [Git User's Manual](http://schacon.github.com/git/user-manual.html) -- a |
| 25 great resource to learn more about ho to use Git properly. | 25 great resource to learn more about ho to use Git properly. |
| 26 * [A Visual Git Reference](http://marklodato.github.com/visual-git-guide/index
-en.html) | 26 * [A Visual Git Reference](http://marklodato.github.com/visual-git-guide/index
-en.html) |
| 27 -- a resource that explains various Git operations for visual reasons. | 27 -- a resource that explains various Git operations for visual learners. |
| 28 * [Git Cheat Sheet](http://cheat.errtheblog.com/s/git) -- now that you | 28 * [Git Cheat Sheet](http://cheat.errtheblog.com/s/git) -- now that you |
| 29 understand Git, here's a cheat sheet to quickly remind you of all the | 29 understand Git, here's a cheat sheet to quickly remind you of all the |
| 30 commands you need. | 30 commands you need. |
| 31 | 31 |
| 32 ## Committing changes | 32 ## Committing changes |
| 33 | 33 |
| 34 For a simple workflow (always commit all changed files, don't keep local | 34 For a simple workflow (always commit all changed files, don't keep local |
| 35 revisions), the following script handles check; you may wish to call it `gci` | 35 revisions), the following script handles check; you may wish to call it `gci` |
| 36 (git commit) or similar. | 36 (git commit) or similar. |
| 37 | 37 |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 | 116 |
| 117 '\,//, ! s/foo/bar/g' | 117 '\,//, ! s/foo/bar/g' |
| 118 | 118 |
| 119 ## Diffs | 119 ## Diffs |
| 120 | 120 |
| 121 git diff --shortstat | 121 git diff --shortstat |
| 122 | 122 |
| 123 Displays summary statistics, such as: | 123 Displays summary statistics, such as: |
| 124 | 124 |
| 125 2104 files changed, 9309 insertions(+), 9309 deletions(-) | 125 2104 files changed, 9309 insertions(+), 9309 deletions(-) |
| OLD | NEW |