Skip to content

Commit f00c42e

Browse files
HonkingGooseben
andauthored
Rewrite into something nicer
Co-authored-by: Ben Straub <[email protected]>
1 parent c94a240 commit f00c42e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

book/03-git-branching/sections/rebasing.asc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -229,12 +229,12 @@ That's how it happened, and the repository should preserve that for posterity.
229229

230230
The opposing point of view is that the commit history is the *story of how your project was made.*
231231
You wouldn't publish the first draft of a book, so why show your messy work?
232-
Remember, you are likely to need this history yourself, when fixing a bug, or figuring out why you made a particular change.
233-
People in this camp clean up their commit(s) and commit messages, before the work is merged/rebased into the mainline branch.
232+
When you're working on a project, you may need a record of all your missteps and dead-end paths, but when it's time to show your work to the world, you may want to tell a more coherent story of how to get from A to B.
233+
People in this camp use tools like rebase and filter-branch to rewrite their commits before they're merged into the mainline branch.
234234
They use tools like `rebase` and `filter-branch`, to tell the story in the way that's best for future readers.
235235

236236
Now, to the question of whether merging or rebasing is better: hopefully you'll see that it's not that simple.
237237
Git is a powerful tool, and allows you to do many things to and with your history, but every team and every project is different.
238238
Now that you know how both of these things work, it's up to you to decide which one is best for your particular situation.
239239

240-
You can get the best of both worlds: rebase local changes before pushing to clean up your work, but never rebase anything that you've pushed somewhere.
240+
You can get the best of both worlds: rebase local changes before pushing to clean up your work, but never rebase anything that you've pushed somewhere.

0 commit comments

Comments
 (0)