96 | | This is where it gets interesting... |
| 96 | This is where it gets interesting... Here are the steps to prepare student work for a PR to the main repository, |
| 97 | and to switch to fresh base and staging branches for additional student work. |
| 98 | |
| 99 | * Make sure there are no branches called base_done and staging_done in the edengci repository. That would mean the |
| 100 | previous aggregation cycle is incomplete, or the branches were not cleaned up. Talk to the other mentors to find |
| 101 | out what happened. When that's resolved... |
| 102 | * If there are any open student PRs: |
| 103 | * Post a note to the student GCI announcements thread in the sahana-eden mailing list asking students to pause in |
| 104 | sending PRs until you say it's ok. (We'll add a link here to the announcements thread when it's ready.) |
| 105 | * Open the web page for each PR, as you'll need to post comments there after they are closed. |
| 106 | * Post a comment in each open PR, telling the student that you're starting an aggregation cycle, and are going |
| 107 | to temporarily close their PR. They should watch for another comment or post in the announcements thread, and |
| 108 | then open their PR again on the (new) staging branch, and rebase it from staging. |
| 109 | * Close the open PRs. |
| 110 | * Make one last check for open PRs in case any snuck in... |
| 111 | |
| 112 | * Rename the base and staging branches on !GitHub, as follows: |
| 113 | * If you have local branches called base or staging, rename or delete them, e.g.: |
| 114 | {{{ |
| 115 | git branch -m staging staging_old |
| 116 | git branch -m base base_old |
| 117 | }}} |
| 118 | * Pull copies of base and staging from the edengci repository. |
| 119 | {{{ |
| 120 | git pull edengci staging |
| 121 | git pull ededgci base |
| 122 | }}} |
| 123 | * Rename them. |
| 124 | {{{ |
| 125 | git branch -m staging staging_done |
| 126 | git branch -m base base_done |
| 127 | }}} |
| 128 | * Push to their new names. |
| 129 | {{{ |
| 130 | git push edengci staging_done |
| 131 | git push edengci base_done |
| 132 | }}} |
| 133 | |
| 134 | * Make fresh base and staging branches. (The commands show assume that "upstream" is the name of the remote |
| 135 | you use for the main repository. If not, use whatever your remote name is.) |
| 136 | {{{ |
| 137 | git pull upstream master:base |
| 138 | git push edengci base |
| 139 | git push edengci base:staging |
| 140 | }}} |
| 141 | |
| 142 | * At this point, the new staging branch is ready for business. Post on the GCI announcement thread that |
| 143 | students can re-open any PRs that had to be closed to rename staging, and can add new PRs. |
| 144 | |
| 145 | * Post a comment in each closed PR telling the student they should now rebase their work from the (new) |
| 146 | staging branch, fix any conflicts, and do another PR. |
| 147 | |
| 148 | * Next, prepare for the PR to the main repository. Check out staging_done. |
| 149 | {{{ |
| 150 | git checkout staging_done |
| 151 | }}} |
| 152 | |
| 153 | * Run the test suite on your local copy of staging_done. If all has gone well with individual code reviews, |
| 154 | there should be no problem here. But if there is, work with the student whose commit has the problem to |
| 155 | resolve it. The student may need to do a PR to staging_done. Or you may want to fix the issue if it is |
| 156 | minor and not due to a problem with the student's work. Don't bother with attempting to squash commits |
| 157 | here, as we want to retain the student names as authors of the their commits. |
| 158 | |
| 159 | * Run Eden from the staging_done branch. Go through the students' PR pages, and look for their comment |
| 160 | about how to observe their change. Do that, and check that it still works. Again, if there's a problem, |
| 161 | work with the student to fix it. |
| 162 | |
| 163 | * If there were any fixups needed, push them to the staging_done branch. |
| 164 | |
| 165 | * Do a PR to the main repository. Add a comment with the PR that tells what is in it -- should be able to |
| 166 | scrape these from the students' PRs. As a courtesy, also scrape the student's instructions for testing -- |
| 167 | Mark this so it's easily distinguished from the descriptive comment. |