David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 1 | Change Screen - Introduction |
| 2 | ============================ |
| 3 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 4 | As of Gerrit 2.8 the change screen was redesigned from the ground up. The old |
David Pursehouse | 62d056c | 2013-10-08 18:42:59 +0900 | [diff] [blame] | 5 | change screen is deprecated and will be discontinued in one of the next Gerrit |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 6 | releases. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 7 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 8 | The design spirit of the new change screen is simplicity: only one patch set is |
| 9 | presented on the screen. The list of related changes is always visible and |
| 10 | optional elements are moved to pop down boxes. |
| 11 | |
| 12 | This is not only a facelift. The main highlights are under the hood: |
| 13 | |
| 14 | * Old style RPC calls are replaced by the REST API |
| 15 | * The prettify syntax highlighting library was replaced by Codemirror |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 16 | * Automatic refresh of open changes |
| 17 | * Support to download a patch direct in browser: no local repo is needed |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 18 | * JS API integration: it was never so easy to add change/revision actions to |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 19 | the UI from a plugin. |
| 20 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 21 | This document is intended to help users to switch to the new change screen. |
| 22 | |
| 23 | Further information on the topic can be found in the: |
| 24 | link:https://groups.google.com/forum/#!topic/repo-discuss/6Ryz9p6AzgE[ |
| 25 | CodeScreen2 thread on the repo-discuss mailing list]. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 26 | |
| 27 | [[configuration]] |
| 28 | Configuration |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 29 | ------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 30 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 31 | The new change screen is deactivated by default. It can be activated system-wide |
| 32 | by changing the link:config-gerrit.html[gerrit.changeScreen] setting to |
| 33 | `CHANGE_SCREEN2`. Users can deactivate it by setting `OLD_UI` on their user |
| 34 | preferences page. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 35 | |
| 36 | [[switching-between-patch-sets]] |
| 37 | Switching between patch sets |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 38 | ---------------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 39 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 40 | As already mentioned above, the main difference between the old and the new |
| 41 | change screen is the fact that only one patch set is presented on the screen. |
| 42 | |
| 43 | To switch to other patch sets for the given change, the drop down 'Revisions' |
| 44 | box is used on the right upper side of the change header. |
| 45 | |
| 46 | Patch sets are always sorted in descending order. The option to switch between |
| 47 | ascending and reverse patch set sorting order is not supported on the new change |
| 48 | screen. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 49 | |
| 50 | [[download-commands]] |
| 51 | Download commands |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 52 | ----------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 53 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 54 | The download commands are moved to the 'Download' drop down box. Patch files |
| 55 | can be downloaded as base64 encoded or zipped versions. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 56 | |
| 57 | [[quick-approve]] |
| 58 | Quick approve |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 59 | ------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 60 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 61 | The so called 'Quick approve' button is some times confusing. Normal users (i.e. |
| 62 | non-maintainers) see this as 'Verified+1' button to the right of the 'Reply' |
| 63 | button. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 64 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 65 | The button is not always "Verified+1". The button appears if a user has |
| 66 | permission to vote the max score in exactly one label that the rules have marked |
| 67 | as NEED. |
| 68 | |
| 69 | For a maintainer with both 'Verified+1' and 'Code-Review+2' powers the button |
| 70 | does not appear, as both categories are still marked NEED and the maintainer has |
| 71 | permission to use both. If another maintainer scores 'Code-Review+2', then the |
| 72 | button displays as 'Verified+1'. If a verifier scores 'Verified+1' the button |
| 73 | displays as 'Code-Review+2'. |
| 74 | |
| 75 | It is important to note that by design, the user cannot provide a comment when |
| 76 | using this button, hence the name 'Quick approve'. To provide comments, the |
| 77 | 'Reply' button should be used. |
| 78 | |
| 79 | [[reply-button]] |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 80 | Reply button |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 81 | ------------ |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 82 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 83 | This button corresponds to the 'Review' button the on patch set panel on the old |
| 84 | change screen. The only new feature: the user can optionaly send an email |
| 85 | during the vote. |
| 86 | |
| 87 | Key bindings: "a" to open the drop down. "ESC" to close it. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 88 | |
| 89 | |
| 90 | [[edit-commit-message]] |
| 91 | Edit commit message |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 92 | ------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 93 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 94 | To edit the commit message use the 'Edit Message' button on the change header, |
| 95 | which will open a drop-down editor box. |
| 96 | |
| 97 | Key bindings: "e" to open the drop down. "ESC" to close it. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 98 | |
| 99 | [[edit-change-topic]] |
| 100 | Edit change topic |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 101 | ----------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 102 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 103 | To edit the topic use the edit icon to the right of the topic field. |
| 104 | |
| 105 | Key bindings: "t" to open the drop down. "ESC" to close it. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 106 | |
| 107 | [[abandon-restore]] |
| 108 | Abandon or Restore changes |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 109 | -------------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 110 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 111 | When a change is abandoned or restored, a panel appears and a comment message |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 112 | can be provided. |
| 113 | |
| 114 | [[working-with-drafts]] |
| 115 | Working with draft changes and patch sets |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 116 | ----------------------------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 117 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 118 | When a change or a patch set is a draft, then three additional buttons appear on |
| 119 | the action panel: 'Publish', 'Delete Revision', and 'Delete Change'. In the |
| 120 | 'Revisions' drop down a "(DRAFT)" suffix is added to the patch set number to |
| 121 | indicate that the patch set is a draft. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 122 | |
| 123 | [[draft-comments]] |
| 124 | Highlight draft comments |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 125 | ------------------------ |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 126 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 127 | If a patch set has draft comments that weren't published yet, then that patch |
| 128 | set is marked on the list in the 'Revisions' drop down list. In addition a red |
| 129 | "draft" prefix appears on the filenames in the file table. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 130 | |
| 131 | [[codemirror]] |
| 132 | Codemirror |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 133 | ---------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 134 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 135 | On the user preferences page, 'Side By Side' or 'Unified Diff' view can be |
| 136 | configured. Use the "/" key to start the CodeMirror search, like in vim. |
| 137 | |
| 138 | Key bindings are not customizable at the moment. They may be added in the future. |
| 139 | |
| 140 | Range comments are supported on Codemirror's 'Side By Side' screen. Highlight |
| 141 | lines with the mouse and then click the bottom-most line number to create a |
| 142 | range comment for the highlighted lines. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 143 | |
| 144 | [[reviewers]] |
| 145 | Reviewers |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 146 | --------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 147 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 148 | Reviewer are split into two groups: Reviewers who actually voted on the change |
| 149 | in the 'Reviewers' field, and reviewers, who were added to the change but didn't |
| 150 | vote yet in the 'CC' field. |
| 151 | |
| 152 | The votes per category are listed above the File list. |
| 153 | |
| 154 | To add a reviewer, use the '[+]' button to the right of the 'CC' field. Typing |
| 155 | into the pop-up text field activates auto completion of user or group names. |
| 156 | |
| 157 | To remove reviewers click on the 'x' icon in the reviewer's "chip". |
| 158 | |
| 159 | Key bindings: "c" to add a reviewer. "ESC" to close the drop down. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 160 | |
| 161 | [[auto-refresh]] |
| 162 | Auto refresh of change data |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 163 | --------------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 164 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 165 | On the new change screen polling for updates to the currently open change is |
| 166 | activated per default. For example, if another user votes or comments on the |
| 167 | same change, then a popup window appears on the bottom right corner of the |
| 168 | screen to notify the user that the change was updated. |
| 169 | |
| 170 | The default delay is 30 seconds. It can be configured with the |
| 171 | link:config-gerrit.html[change.updateDelay] setting. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 172 | |
| 173 | [[depends-on-needed-by]] |
| 174 | "Depends on" and "Needed by" |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 175 | ---------------------------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 176 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 177 | Dependencies and dependent changes are listed in the 'Related Changes' drop |
| 178 | down. |
| 179 | |
| 180 | Key bindings: "J" & "K" to navigate between the related changes. "O" to |
| 181 | open the currently selected related change. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 182 | |
| 183 | [[file-table]] |
| 184 | File table |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 185 | ---------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 186 | |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 187 | The user can now manually toggle the 'reviewed' flag per file using the check |
| 188 | box to the left of the filename. |
| 189 | |
| 190 | Key bindings: "j" & "k" to navigate in the file table, and "r" to toggle the |
| 191 | 'reviewed' flag. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 192 | |
| 193 | [[included-in]] |
| 194 | Included in |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 195 | ----------- |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 196 | |
| 197 | To see the branches a specific change was merged into and the list of the tags |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 198 | a change was tagged with, use the 'Included In' drop down on the change header, |
| 199 | to the left of the 'Revisions' drop down. |
| 200 | |
| 201 | Note that this list is only visible on merged changes. |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 202 | |
| 203 | [[missing-features]] |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 204 | Missing features |
Yuxuan 'fishy' Wang | ec3a954 | 2013-10-07 20:37:14 -0700 | [diff] [blame] | 205 | ---------------- |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 206 | |
| 207 | Several features have not been implemented yet: |
David Ostrovsky | 4b3c378 | 2013-10-03 21:12:13 +0200 | [diff] [blame] | 208 | |
| 209 | * Permalink a change |
| 210 | * Allow to see if a reviewer can't vote on a label |
| 211 | * Allow to select a reference version as base for the comparison |
David Pursehouse | 305e5d7 | 2013-10-04 20:44:15 +0900 | [diff] [blame] | 212 | * Change diff view preferences |
David Pursehouse | 62d056c | 2013-10-08 18:42:59 +0900 | [diff] [blame] | 213 | |
| 214 | GERRIT |
| 215 | ------ |
| 216 | Part of link:index.html[Gerrit Code Review] |