Chromium Code Reviews| OLD | NEW | 
|---|---|
| 1 #!/usr/bin/env bash | 1 #!/usr/bin/env bash | 
| 2 . demo_repo.sh | 2 . demo_repo.sh | 
| 3 | 3 | 
| 4 silent git push origin refs/remotes/origin/master:refs/branch-heads/9999 | 4 silent git push origin refs/remotes/origin/master:refs/branch-heads/9999 | 
| 5 silent git config --add remote.origin.fetch \ | 5 silent git config --add remote.origin.fetch \ | 
| 6 +refs/branch-heads/*:refs/remotes/branch-heads/* | 6 +refs/branch-heads/*:refs/remotes/branch-heads/* | 
| 7 silent git fetch origin | 7 silent git fetch origin | 
| 8 | 8 | 
| 9 silent git checkout -b master origin/master | 9 silent git checkout -b master origin/master | 
| 10 add modified_file | 10 add modified_file | 
| 11 set_user some.committer | 11 set_user some.committer | 
| 12 c "This change needs to go to branch 9999" | 12 c "This change needs to go to branch 9999" | 
| 13 silent git tag pick_commit | 13 silent git tag pick_commit | 
| 14 | 14 | 
| 15 comment Before working with branches, you must \'gclient sync \ | 15 comment Before working with branches, you must \'gclient sync \ | 
| 16 --with_branch_heads\' at least once to fetch the branches. | 16 --with_branch_heads\' at least once to fetch the branches. | 
| 17 | 17 | 
| 18 set_user branch.maintainer | 18 set_user branch.maintainer | 
| 19 tick 1000 | 19 tick 1000 | 
| 20 | 20 | 
| 21 echo "# Make sure we have the most up-to-date branch sources." | |
| 22 run git fetch | |
| 23 echo | |
| 24 echo "# Here's the commit we want to 'drover'." | |
| 21 run git log -n 1 --pretty=fuller | 25 run git log -n 1 --pretty=fuller | 
| 26 echo | |
| 27 echo "# Checkout the branch we want to 'drover' to." | |
| 22 run git checkout -b drover_9999 branch-heads/9999 | 28 run git checkout -b drover_9999 branch-heads/9999 | 
| 23 echo "# DO NOT leave off the '-x' flag" | 29 echo | 
| 30 echo "# Now do the 'drover'." | |
| 31 echo "# IMPORTANT!!! Do Not leave off the '-x' flag" | |
| 24 run git cherry-pick -x $(git show-ref -s pick_commit) | 32 run git cherry-pick -x $(git show-ref -s pick_commit) | 
| 33 echo | |
| 34 echo "# That took the code authored by some.commiter and commited it to the" | |
| 35 echo "# branch by branch.maintainer (us)." | |
| 25 run git log -n 1 --pretty=fuller | 36 run git log -n 1 --pretty=fuller | 
| 37 echo | |
| 38 echo "# Looks good. Ship it!" | |
| 26 pcommand git cl upload | 39 pcommand git cl upload | 
| 
 
iannucci
2014/08/25 23:38:37
mention that you can skip this and just do the `la
 
Michael Moss
2014/08/25 23:47:33
Done.
 
 | |
| 27 echo "# Get LGTM or TBR." | 40 echo "# Get LGTM or TBR." | 
| 28 run git cl land | 41 run git cl land | 
| OLD | NEW |