On 27/03/12 17:24, Amir E. Aharoni wrote: > It sounds similar to what i said in the thread "consecutive commits in > Gerrit‏", so i probably support it, but i don't completely understand > how will it work with the `git review' command, which doesn't like > multiple commits. If the documentation will explain how to use `git > review' with follow up commits, it will be fine.
I've done a few test commits, it will work. The procedure is to copy the download command out of the Gerrit change page and paste it into a shell, same as amending. Git gives you some output which includes: : If you want to create a new branch to retain commits you : create, you may do so (now or later) by using -b with the : checkout command again. Example: : git checkout -b new_branch_name You follow its instructions, creating a branch: : git checkout -b my_test_commit Then edit the files, then instead of amend, just a regular : git commit -a : git review It complains that you're committing two things: : You have more than one commit that you are about to submit. : The outstanding commits are: : : 6e4f490 (HEAD, test2) test 2 : 634b5d7 (junk-2) Test commit 1 : : Is this really what you meant to do? : Type 'yes' to confirm: You answer "yes", then it's done. Here's what the result looks like: https://gerrit.wikimedia.org/r/#change,3794 git review --no-rebase may be necessary to reduce noise on the parent change pages, I haven't tested that yet. It can be done with slightly fewer steps if you make the steps more complicated. -- Tim Starling _______________________________________________ Wikitech-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/wikitech-l
