branching-and-merging

merge /discard reports 'No Pending Changes' when /candidate shows them

前提是你 提交于 2019-12-05 16:17:27
I'm trying to run a merge /discard command ( tfs merge /discard /version:nnn:yyy $/sourceproj $/targetproj /recursive ) but it says there are no pending changes. If I run a tfs merge /candidate $/sourceproj $/targetproj it shows the relevant changesets as candidates. any ideas why this happens and how to get round it? Thanks. If you know the exact changeset number try: tf merge /discard /version:C111~C111 BranchX BranchY /recursive This assumes you know the changeset number (in this case 111). If that doesn't work, then can you update your question to give the exact values you are entering

Mercurial merge repository as branch

假如想象 提交于 2019-12-05 13:54:46
I have two Mercurial repositories that are for different major revisions of the same project. The latter version is a massive change to the functionality, and especially the UI, of the project, but it will still have a lot of common code with the earlier version. (For shorthand I'll call these versions 4.6 and 5.0 and the repositories project-4.x and project-5.x going forward; that's basically what I'm dealing with.)[1] As we thought more carefully about the structure of our repository, and thinking especially about how to handle the related code, it became apparent that we wanted to simply

Git pull reverted commits in master?

删除回忆录丶 提交于 2019-12-05 13:42:37
A colleague, whom we'll call Aaron, was assigned to renovate a section of a website as a long-term project. He created a new Git branch, called aaron . All his changes were made on this branch. While he was working, I continued to maintain the site as a whole, committing my changes to master . Eventually, Aaron merged his branch into master . This somehow reverted all of the commits I'd made to master between the time of the merge and the time when the aaron branch was first created. If I type git show <hash of merge commit> , I can see diffs for every file I changed while Aaron was working on

Should we remove a remote Git branch after merging to master?

时光怂恿深爱的人放手 提交于 2019-12-05 13:12:56
I would like to know if it's better to delete your branch after merging to master or if we should continue to work on the same separate branch during all the project. i.e If we are 3 members in the group, each of us create his own branch and works on it during the duration of the project. We all commit in the master branch and pull before we start working on something else. In that way, we know who's working on which branch and we don't get confuse. Thanks. So there are tons of literature about how to manage your branches but really I think it comes down to how you want to manage things within

Commit select changes to another branch then resume work on current branch?

时光毁灭记忆、已成空白 提交于 2019-12-05 12:18:33
问题 This happens often in my work flow: I'm working on a feature in a separate branch, and while doing this I'll come across small things that need fixing but are from higher up in the framework or site layout for example. I want to switch back to the main develop branch and commit changes from select files there, then go back to a feature branch, and rebase so that I can continue there with the unrelated tweaks/bugfixes out of the way. I'm using git stash and git stash pop to do this, but I'm

Why would my local changes in Git be overwritten by checkout in this circumstance?

末鹿安然 提交于 2019-12-05 11:44:58
Say I have a branch A, and from that I branch B. I make a bunch of changes on A, then checkout B and do a git pull . Now I make a change on B but realize that it should've been in A. If I now try to git checkout A , I get "Your local changes to the following files would be overwritten by checkout" to the file I touched. Why would my change be overwritten if I just did a git pull in B and haven't touched that file in A since? The reason you get that message is that the underlying file (before your uncommitted modifications) is different between branch A and branch B. If the files were the same,

Switch the svn branch git dcommits to

梦想的初衷 提交于 2019-12-05 09:12:09
I had master dcommit to (and rebase from) the Subversion trunk . I created an intermediate Subversion branch tc , to merge changes from 2 different branches, using: git branch master git svn branch tc -m "Branch for merging" git checkout -b tcl --track tc git merge cat #Another branch, whose changes I merged here git commit -m 'Merged changes from cat branch' git svn dcommit Since everything was fine, I wanted to promote this to the trunk . I followed doing: git branch master git merge tcl git svn dcommit Now, because master was merged from another branch that was pointing to a different

What are the consequences of renaming a branch in TFS 2012?

你。 提交于 2019-12-05 08:45:14
问题 I've read in many places that renaming a branch is rather problematic in TFS 2010 : you may lose the history of the branch you just renamed ( as seen in this article or in this SO question ) I cannot find any mention of those problems in TFS 2012. Are there any consequences I should be aware of before renaming a branch in TFS 2012 ? 回答1: The biggest problem with renaming a branch, is that you will effectively be performing a baseless merge next time you merge to or from the renamed branch.

VSTS and Git: Why does squashing my DEV branch while merging to master says that DEV is both behind and ahead of master?

北慕城南 提交于 2019-12-05 05:45:05
I'm hoping someone can help me with this as I'm scratching my head to understand what is going on, and if it can be rectified. I'm currently working on a project in VSTS and using GIT as the code repository. I have the usual MASTER branch, with a DEVELOPMENT branch coming off that. I then create feature branches off the DEVELOPMENT branch. When we have finished the changes in the feature branch, I create a Pull Request and can successfully merge the changes into the DEV branch. The DEV branch then shows '0' behind and 'x' ahead of MASTER ... which is correct. The issue comes when we are ready

SVN merge reintegrate missing ranges but nothing to merge

自作多情 提交于 2019-12-05 05:11:14
Here is the riddle: C:\code\trunk> svn merge --reintegrate http://svn.e.com/repos/branches/lih --accept postpone --dry-run svn: E195016: Reintegrate can only be used if revisions 11430 through 12384 were previously merged from http://svn.e.com/repos/trunk to the reintegrate source, but this is not the case: branches/lih Missing ranges: /trunk:11902 But then if I go into the branch's directory and try to merge that range, there is nothing to merge! C:\code\branches\branch> svn merge -r 11901:11902 http://svn.e.com/repos/trunk --accept postpone --dry-run C:\code\branches\branch> Even svn merge