annotate help/a-33.html @ 547:9f91d1b2ed51 fswatcher

Release mode
author Chris Cannam
date Tue, 14 Feb 2012 17:53:29 +0000
parents f56e5c39aad1
children
rev   line source
Chris@499 1 <link rel="stylesheet" type="text/css" href="help.css"/>
Chris@499 2
Chris@499 3
Chris@499 4 <h2>I tried to push my changes, but it told me &ldquo;the remote repository may have been changed by someone else&rdquo; and refused</h2>
Chris@499 5
Chris@500 6 <p>This indicates that the remote repository has some changes in it that
Chris@500 7 you do not have in your local repository (and that are in branches
Chris@500 8 that you have also changed).</p>
Chris@500 9
Chris@500 10 <p>Perhaps someone else made these changes and pushed them, or they may
Chris@500 11 have been pushed by you from a different computer.</p>
Chris@500 12
Chris@500 13 <p><b>Why should that prevent me from pushing my changes?</b></p>
Chris@499 14
Chris@499 15 <p>A good principle is that you should review and test your changes
Chris@500 16 before you push them to another repository. It may be OK to commit
Chris@499 17 changes locally that don't really work or that aren't complete enough
Chris@500 18 to test, but it's a bad idea to push anything that would cause the
Chris@500 19 remote repository to have an untested set of changes in it.</p>
Chris@499 20
Chris@500 21 <p>For this reason, if you change some files, someone else changes some
Chris@500 22 others, and you both try to push them without knowing about the other
Chris@500 23 one, Mercurial must refuse the second push &ndash; it can't simply merge
Chris@500 24 the changes because the result might not make any sense.</p>
Chris@499 25
Chris@499 26 <p>Instead you must pull the other person's changes and merge them
Chris@500 27 locally before you push. Fortunately, this is easy to do:</p>
Chris@499 28
Chris@499 29 <p><b>1. Click Pull on the main toolbar at the top of the EasyMercurial window.</b>
Chris@499 30 <ul><li>You should see that some changes are pulled and added to your local repository. This will usually lead to a forked graph in the History pane, as your changes and the other user's were both started from the same parent at the same time.</li></ul></p>
Chris@499 31
Chris@499 32 <p><b>2. Click Merge in the toolbar on the left.</b>
Chris@531 33 <ul><li>Any changes that affect different files, or that affect different parts of the same file, will be merged automatically. For changes that affect the same parts of the same file, you will be asked to choose which change to include in the merged copy. See <a href="a-34.html">How do I merge my changes...</a> for more about this.</li></ul></p>
Chris@499 34
Chris@499 35 <p><b>3. Review or test the resulting merged version in your local working folder.</b></p>
Chris@499 36
Chris@499 37 <p><b>4. Commit the merged version.</b></p>
Chris@499 38
Chris@499 39 <p><b>5. Push again to the remote repository.</b></p>
Chris@499 40