[8979] | 1 | This file contains a description of the process developers should go |
---|
| 2 | through to get changes into the source tree. Although it discusses |
---|
| 3 | the use of CVS, it is not a CVS tutorial; read the CVS info pages |
---|
| 4 | (available in M-x info in emacs on Athena) for a general introduction |
---|
| 5 | to CVS. Areas covered in this file are: |
---|
| 6 | |
---|
| 7 | Checking out a working directory |
---|
[9000] | 8 | Preparing changes for review |
---|
| 9 | Reviewing changes |
---|
[8980] | 10 | Updating third-party sources |
---|
[8979] | 11 | |
---|
| 12 | You should use cvs from the gnu locker with the source repository. |
---|
| 13 | People without write access to the repository can use "cvs -u" (a |
---|
| 14 | local modification to CVS) to access the repository without making |
---|
| 15 | read locks. If you do not have write access to the repository and you |
---|
| 16 | want to submit a change, follow the guidelines below up and including |
---|
| 17 | sending mail to source-reviewers, and note in your mail that your |
---|
| 18 | reviewer should check in the change because you cannot do so. |
---|
| 19 | |
---|
| 20 | Checking out a working directory |
---|
| 21 | -------------------------------- |
---|
| 22 | |
---|
| 23 | Set CVSROOT to "/afs/dev.mit.edu/source/repository" before trying to |
---|
| 24 | check out a working directory. |
---|
| 25 | |
---|
| 26 | The entire source tree is very large. You can check it out with "cvs |
---|
| 27 | co all", but in almost all cases this would be a big waste of space. |
---|
| 28 | Simply check out a subdirectory of the source tree with a command like |
---|
| 29 | "cvs co athena/bin/olc". |
---|
| 30 | |
---|
| 31 | CVS knows nothing about AFS permissions, so all directories created |
---|
| 32 | will have the same permissions as their parent. It is generally |
---|
| 33 | safest to do your checkouts in a private area of the filesystem. |
---|
| 34 | |
---|
[9000] | 35 | Preparing changes for review |
---|
| 36 | ---------------------------- |
---|
[8979] | 37 | |
---|
| 38 | Changes to the doc hierarchy do not typically need to be reviewed; |
---|
| 39 | notification is typically good enough, since no software will break as |
---|
| 40 | a result of changes to the source tree documentation. |
---|
| 41 | |
---|
[9000] | 42 | For changes to other parts of the tree, you should perform the |
---|
| 43 | following steps while preparing your changes for review: |
---|
[8979] | 44 | |
---|
[9000] | 45 | 1. Do a "cvs update" in your working directory to merge in |
---|
| 46 | changes other people may have made. (You can do "cvs -n |
---|
| 47 | update" if you want to see what needs to be merged in |
---|
| 48 | without actually doing the merge.) |
---|
[8979] | 49 | |
---|
[9000] | 50 | 2. Be sure to test your changes. |
---|
[8979] | 51 | |
---|
[9000] | 52 | 3. Use "cvs diff -c -N" piped to a file to prepare your |
---|
| 53 | changes. (Do not cut and paste diffs from an xterm; your |
---|
| 54 | tabs will be converted to spaces.) |
---|
| 55 | |
---|
| 56 | 4. Look over your diffs. Make sure you haven't been sloppy |
---|
| 57 | about spacing, punctuation, and naming, and that you have |
---|
| 58 | tried to conform to the guidelines in the file "standards" |
---|
| 59 | in this directory |
---|
| 60 | |
---|
| 61 | 5. Send your diffs, along with a clear description of the |
---|
| 62 | change you are making, to source-reviewers@mit.edu. |
---|
| 63 | |
---|
[8979] | 64 | Ideally, at least one person will respond to your mail within a day or |
---|
| 65 | two, either expressing concerns or signing onto your change. You |
---|
| 66 | should wait at least one full working day for people to voice their |
---|
| 67 | objections. If you receive objections or requests for further |
---|
| 68 | information from staff members, you must either satisfy those concerns |
---|
| 69 | or resolve the issue with the release team before committing your |
---|
| 70 | change. If after one day, you have received no objections and someone |
---|
[9484] | 71 | has signed onto your change, you may commit your change. You may also |
---|
| 72 | commit your change if no one objects within five days, even if no one |
---|
| 73 | has signed onto it. |
---|
[8979] | 74 | |
---|
[9000] | 75 | When you check in your change, be sure to include a clear log message. |
---|
| 76 | Explain why you are making the change you are making if it's not |
---|
[9707] | 77 | obvious. |
---|
[9000] | 78 | |
---|
| 79 | Reviewing changes |
---|
| 80 | ----------------- |
---|
| 81 | |
---|
[9484] | 82 | Sometimes you can review a change by looking at the patch. Other |
---|
| 83 | times you will want to check out a tree and apply the patch, with |
---|
| 84 | "patch -E -p < message-file" if you have the mail message in a file, |
---|
| 85 | or "dsgrep -p -t trn-number source-reviewers | patch -E -p" if what |
---|
| 86 | you have is a transaction number in the source-reviewers discuss |
---|
| 87 | meeting. |
---|
| 88 | |
---|
[8979] | 89 | When reviewing a change, be sure to make your position on the change |
---|
| 90 | clear. Say "I object to this change" if you are not merely voicing a |
---|
| 91 | concern, or "I would like these questions answered before this change |
---|
| 92 | is committed" if you have asked questions and are not merely curious. |
---|
| 93 | When your objections are responded to, you should in turn respond in a |
---|
| 94 | timely fashion saying whether your objections have been satisfied or |
---|
| 95 | not. If the dispute appears intractable, say so, so that the issue |
---|
| 96 | may be brought up before the release team. |
---|
| 97 | |
---|
| 98 | If you have reviewed a change carefully and have found nothing wrong |
---|
| 99 | with it, and no one else has responded to the change, you should sign |
---|
| 100 | onto the change rather than remaining silent. You are encouraged to |
---|
[9484] | 101 | try out changes before signing onto them, but in some cases the |
---|
| 102 | inconvenience outweights the benefit of this consideration. |
---|
[8979] | 103 | |
---|
[8980] | 104 | Updating third-party sources |
---|
| 105 | ---------------------------- |
---|
| 106 | |
---|
| 107 | For modules in the third hierarchy, we generally use the "cvs import" |
---|
| 108 | command to track development from outside. (To find out if this |
---|
| 109 | applies to a given module, to a "cvs log" of a file in the tree; if |
---|
[10518] | 110 | you see a revision 1.1.1.1, then we're using cvs import.) Do not |
---|
| 111 | check in a new outside version of a third-party package onto the |
---|
| 112 | mainline if it was originally imported with cvs import; it's very |
---|
| 113 | difficult to recover from that particular mistake. Do, however, check |
---|
| 114 | local changes you made yourself onto the mainline. Always refer to |
---|
| 115 | doc/third-party before doing an import to see if there are any special |
---|
| 116 | notes on the module you are importing. |
---|
[8980] | 117 | |
---|
| 118 | Generally, you should only import "clean" third-party source trees |
---|
[9000] | 119 | with no modifications. If you absolutely need to make changes to the |
---|
| 120 | source tree before importing it (check with a release engineer before |
---|
| 121 | deciding that you have to), make a note in the doc/third-party file so |
---|
| 122 | that people doing future imports will know about it. |
---|
[8980] | 123 | |
---|
[8979] | 124 | If you add a new piece of third-party software or import a new |
---|
| 125 | version, you should look over doc/third-party and see if any notes |
---|
| 126 | should be added or modified. This file is instrumental in locating |
---|
| 127 | new versions of software. |
---|