FAQ Database Discussion Community


Why do Branch and Merge use the same symbol in UML Activity diagrams?

merge,uml,branch,activity-diagram
What is the rationale behind Branch and Merge using the same symbol? I find it confusing, because you can't rely on the shape to know whether there's a conditional going on or not. Is there some other standard symbol or symbol variation I can use? I would rather avoid connecting...

Gitolite restrict access to branch

branch,gitolite,policy,restrict
I have GITOLITE on my server and I want to configure access to my repository. I want to restrict access to some branches for some users. I try a lot of variants how to configure gitolite.conf file and I didn't find solution how to restrict acces to some branches. 1)...

Safe to Git commit passwords to a branch that never gets pushed?

git,version-control,branch,sensitive-data
If I have two branches, master & secret. And I commit sensitive data into secret, but never push secret, only push master to a public repo. If I never merge between them, only rebase secret, is there any chance my sensitive data could end up in the remote repository index...

How do I connect two broken lines along the same direction in matlab

matlab,tree,branch
I'm trying to select a vessel branch based on user selection. I've already got the center lines extracted and removed the branch points with a big gap. What I'm thinking to do is if user click on a vessel as a starting point, then it will trace all the way...

undo git pull of wrong branch onto master

git,branch,checkout
I have pulled from a different branch from the remote. The 2 branches are different yet the merge happened silently on my current branch. I am currently working on the "master" branch locally, and it has been updated with the changes of the remote branch - "FE_Changes". How do I...

Mercurial - abandoning loose ends

version-control,mercurial,branch,tortoisehg,branching-and-merging
Due to lack of attention, I have made a rollback ("backout") that I had forgot to merge back into the default branch - which I did not notice until a bit later, causing my local history to look like this: Which seems to disallow pushing ("new remote heads"). If I...

Checkout branch on different remote

git,branch
I have a repo that has another remote upstream besides origin. I can do git checkout origin/master, but when I run git checkout upstream/master, I get: error: pathspec 'upstream/master' did not match any file(s) known to git. This does not work either: $ git fetch upstream From https://github.com/getsentry/sentry * branch...

confused about creating nested branches in git

git,nested,branch
I just started using git and started collaborating with other developers on same code. I have worked a little with SVN before but never had to collaborate with other people on my codebase. Now with collaborators working on same code, I need an efficient workflow. While searching for such, I...

GitHub: How to send one pull request per separate commit?

git,github,branch,pull
I forked a project. I worked on it for a bit. I now have ten different commits, each of which is independent to the other commits. I'd like to send each individual commit as a separate pull request, to let the maintainer of the upstream choose which ones he/she wants....

How to list remote branch without web request?

git,branch,git-remote
i just want to list my local remote branches. but when i run git remote show origin, it needs to take a request to the server. How can i do ?

Git: Why is only 1 merge showing in my history when I have done several?

git,version-control,merge,branch,branching-and-merging
Here is my commit history with git log --pretty=%h --graph (the order of commits goes from bottom to top) * 81e1852 <- I have merged back in twice to get to this * b6cb648 * 3ef6e0b * a1f56c5 * a35a50a * 47b2058 <- I have made a couple of branches...

git: Merge Branches but Keep Commit History

git,version-control,branch,history,rebase
In my git workflow we have one main repository and one branch, master. Everyone pulls from remote master and everyone pushes to remote master. I want to work in my own branch while I prepare a feature. So far my history is something like this: git pull --rebase git checkout...

how convert a .cmd into a PowerShell script?

powershell,batch-file,branch
I have the next file (.cmd): @echo off setlocal for /f %%b in (Branches.txt) do ( set branches=%%b ) call :parse "%branches%" goto :eos :parse set branches=%1 set branches=%branches:"=% for /f "tokens=1* delims=," %%a IN ("%branches%") DO ( if not "%%a" == "" call :sub %%a if not "%%b" ==...

Push local commits on master branch to new remote branch

git,branch
I have local commits on the master branch, but (due to unforeseen external reasons) I now can't push my changes to master and instead need to push them to a new remote branch (that can be merged back to master later). How do I (safely) do that?...

How do I use Git's interactive rebase with a local-only repository (no remote / origin)?

git,branch,rebase,git-rebase,remote-branch
I use git as a local source control system mostly for history and diff tracking. I still want to use rebase to do fixup / squash on WIP commits that I will make periodically. When I try to do git rebase -i though, I get the following: There is no...

GIT: How to insert only a modification in two branch not allowing the two projects are equal

git,branch,push,commit
I have the master branch that from it I created two applications, I made a commit in application A, however realized that this modification is common in both branch. How do I enter just this change in the two branch not allowing the two projects are equal.

Difference between `git branch -f ` and `git checkout ; git reset --hard ` under a clean working tree?

git,branch,git-checkout
Up until now, I have always used git checkout <branch_name>; git reset --hard <hash> to move a branch back to an earlier commit. Then I came across this question, but the answers and comments do not explain in great detail the differences between them. Assuming I have a clean working...

How to split a branch in two with Git?

git,split,branch,rebase,cut
I've made a feature branch from master and then realize at some point that it will be better to start a new branch from this branch. So, how to split a branch in two at a specific commit ? Let me explain with this little schema: I have this: master...

Getting `svn: E160013:` when merging from command line

svn,merge,branch
I have an issue with a feature branch that I'm trying to merge to trunk. The message that I'm getting is this: ➜ trunk svn merge https://svn.vcshost.org/svn/domaindev/branches/Master-Project/feature-branch svn: E160013: '/svn/domaindev/!svn/bc/112033/trunk/Master-Project' path not found Any help would be greatly appreciated. I tried merging from trunk to this feature branch and it...

Would this sequence cause 'master' to be merged into branch 'A'?

git,merge,branch,master
I have any issue where master is getting merged into a branch 'releasebranch1'. The scenario is as follows. Most of the team are working on the release branch: 'releasebranch1'. Occasionally a bug fix is made which needs to to copied to 'master'. So we do this: commit the fix to...

Commits are left behind when branch is deleted after merge

git,garbage-collection,branch
Consider the following merge: After deleting the 'testmerge' branch, its commits remain behind. Are those commits ever going to be deleted (garbage collection)? Remote prune doesn't seem to remove them......

Why should I create new branch in git repository? [duplicate]

git,branch,git-branch
This question already has an answer here: When should you branch? 15 answers If the master is default branch of git repository, why should we create another branch? What is the benefits of creating new branch?...

Can mercurial pull changes from forked repo into a new branch?

version-control,mercurial,branch,branching-and-merging
I have a project, biocommons/hgvs. A contributor forked the project, made some changes, and submitted a pull request. I'd like to make some minor changes to those commits, and I'd prefer to do so in a feature branch. Is there a way to pull the PR commits into a new...

how to make a new branch in visual studio 2015?

git,visual-studio,branch,git-branch
i am using git on visual studio online in visual studio 2015 and am trying to figure out how to create a branch. this is the usual answer on the internet: https://msdn.microsoft.com/en-us/library/hh850437.aspx & https://msdn.microsoft.com/en-us/library/jj190809.aspx#create if you check the image is shows the branch and the drop down arrow where i...

Git Branch Delete Warning - What to Do?

git,merge,delete,branch
I'm new to Git and I am using it for the first time as I develop a Flex application using IntelliJ 14. I am developing on my MacBook and have a local repository. I have created a remote repository on our Fileserver, which is backed up nightly, which I push...

Switch which branch a branch is a branch of in git

git,branch
I'm working in a multi-developer environment on a repository which has a branch called "develop", which is updated frequently. However, there's a few issues with develop, and I'd like to create a branch on my local machine, say "custom_develop", where I can make a couple of commits I don't intend...

Can't change branch: merge conflict because of (already?) untracked file

git,version-control,branch,merge-conflict-resolution
I already had the problem that I couldn't check out a branch (see here). After I forced the checkout (git checkout master -f) and did the merging and tagging, I now want to switch to the develop branch back. This is what I get: git checkout develop MyProject.userprefs: needs merge...

How do I ensure that my local branch tracking remote is identical without additional commits?

git,github,branch,tracking
$ cd my/repo $ git checkout develop $ git fetch origin $ git checkout -b branch origin/branch $ git pull origin HEAD CONFLICT (content): Merge conflict in folder/file.ext Auto-merging folder/file.ext Automatic merge failed; fix conflicts and then commit the result. I am really confused as to why my branch wasn't...

Restore local master after making commits on it

git,github,branch,restore,master
I have cloned a project from github. When I started to develop a new requirement, I forgot to make a new branch and I modified the code on my local master instead in a new branch. Now, I need to restore my local master, I mean, getting the same remote...

Git - folder after changing branch

osx,git,branch,finder
why are some folders(which are not in the repo) are still in my project-folder when I change the branch? I already tried "git clean" but the folder are still there......

Creating new branch in github but it isn't current?

ios,xcode,git,github,branch
I created a new branch in github for the 2nd part of my project. However, when I am on it, my xcode project reverts to an old version (not up do date with last branch) clarification: branch checkpoint-19 created new branch called checkpoint-20 when on checkpoint-20, the project I am...

Gitlab: Can I create a Branch visible to only certain developers?

permissions,authorization,branch,gitlab
Im using gitlab, and I am wondering, is there a simple way to restrict access to a branch to only certain developers? This has to do with time varying disclosure and the ability for certain developers to see some objects models, while other cannot? Ideally this would happen in one...

cannot checkout remote git branch

git,github,branch
I'm in a github local clone. Below is the list of branches: $ git branch -a * master online-demo remotes/origin/HEAD -> origin/master remotes/origin/develop remotes/origin/gh-pages remotes/origin/master remotes/origin/online-demo remotes/pateketrueke/develop remotes/pateketrueke/gh-pages remotes/pateketrueke/master When I try to checkout a remote branch, I get an error: $ git checkout develop error: pathspec 'develop' did not...

VS & TFS: Check-in as new branch

visual-studio,tfs,branch
I was coding as usual, but what was supposed to be a minor change ended up as a big new implementation... New controllers and views and some domain refactoring... because of the time constraint I don't feel comfortable enough to just check-in the code to the trunk... I would like...

Jump to Address after Branching in For Loop in MIPS

c,byte,branch,mips,bit
I am trying to code a program that checks if the 16 bits in an integer is a one or zero. I chose to implement this by shifting right one bit 15 times and checking if the first bit in each shift is a zero or non zero. Then, if...

Specific code for different branches

javascript,git,gruntjs,branch,jetbrains
We have a backbone.js application for a number of devices. While most of the code is common for every device there are some parts that are specific for some of them. It can be some js code or some templates. Currently we have one branch (master) that holds all of...

Can I use `diff …` as an indicator for branch cleanup?

git,branch,branching-and-merging,git-diff
I have branches where git branch -d some_branch returns branch 'some_branch' is not fully merged. But git diff ...some_branch is empty. In other words, (as I understand) there are no changes that exist in "some_branch" that I don't have in the current. But yet it's not "fully merged". Am I...

GitHub Markdown - Add current branch name

github,branch,markdown,placeholder
Just a short question: Is it possible to show the current branch name in e.g. README.md automatically with a placeholder or something like that using GitHub Flavored Markdown?...

Python parser on xml not able to return branches

python,xml,parsing,find,branch
I am currently attempting to parse a downloaded xml file and write to a csv file however I'm a little inexperienced with xml formatting. Regardless I am able to return the elements from the first branch Filing but I am unable to return anything from the following branches such as...

MIPS, why this branch doesn't work?

arrays,branch,mips
I have to do a bne taking one argument from an array declared pp: .space 40, in that array i put integer, 0 or 1, it's a flag. But whatever I do, the bnenever work! How I have to pass the argument?? li $s5, 0 li $t1, 10 la $s0,...

Create branch at specific change set, move changests after this point to different branch

tfs,branch,alm
Hypothetical scenario: By mistake, I've been working away on my 'Main' branch. What I need to do, is effectively reset my Main branch to a particular changeset - 1001 for example. Changesets after 1001, I want to move to a new branch - 'Dev' Is this possible? I come from...

Queue a build from branch B with shelveset from trunk A

visual-studio-2013,tfs,branch,branching-and-merging,shelveset
I'm trying to get a tfs build with a specific shelveset. I need a build of branch A and the shelveset from Branch B. When I right click the build definition of branch A and select 'Queue Build' I can choose 'latest source with shelveset' and selecting the shelve from...

Server to test my app

git,heroku,github,branch,checkout
I am trying to upload my app on Heroku, but when I clone it from Github I get the following errors: error: unable to create a file (Permission denied) fatal: unable to checkout working tree warning: Clone succeeded but checkout failed Maybe the problem can be that I can edit...

Merging strategy with a long development branch. How to prevent heavy conflicts in the future merge?

git,merge,branch,branching-and-merging,branching-strategy
I'm developing a project where I constantly want to make small improvements on master branch and push them to production. I have problem because I want to concurrently work on a branch that will be pushed only after a long time. If I will use different branches on long_project and...

Can't switch branch: untracked working tree file because of case-insensitivity?

osx,git,version-control,branch,case-sensitive
I want to merge the develop branch into the master branch and I thougt I do something like this: git checkout master git merge --no-ff develop git tag -a 1.0.0 but on checkout I get git checkout master error: The following untracked working tree files would be overwritten by checkout:...

choose between two options without random number

java,branch
So, there are two branches and I want the program to choose only one of them randomly. I know this can be done generating a random number and then depending on that number choose one of those paths (using if/else) but what I'm asking is if there's any other way...

SVN: branch issue

svn,version-control,merge,branch
I just started working with SVN. I created a dev branch for myself only, so that I can do whatever I want before merging my changes to the trunk. Unfortunately, when I had to merge, it has been a nightmare. My tree looked like that: trunk : A-B \ dev...

Git: Is there a way to re-merge two commits on the same branch (FF) to a new branch?

git,merge,branch
I'm working on a group project, and after making some changes and pushing to origin (call this commit A), another person seems to have force pushed their changes, thereby reverting my commits (call this commit B). Before I push, we have something like this: A (master) | B (their-master) |...

Making local copy of git branch current

git,branch,bitbucket
I'm using new git tools (BitBucket, SourceTree) and only lightly familiar with git. When I am at BitBucket (in the browser), there are two branches, master and 2.0. I cloned the 2.0 branch locally and then I made rogersbranch off of that, where all of my changes have been made....

Easy way to switch/swap git checkins between 2 branches

git,version-control,merge,branch
I made an implementation for a feature on develop-branch. It worked out well but then I came up with an interesting alternative. I branched from the checkin of develop-branch before the feature checkin on develop to implement the alternative. Now I decided that my alternative is the better implementation. But...

Contradicting Git Messages: Merge and Remove

git,branch,cloud9-ide
Using Cloud9 and having problems because the .c9 folder was added to git. Trying to remove it. Git is asking me to remove a file before I can merge to the master branch. When I try to remove it, git tells me the file doesn't exist. [email protected]:~/workspace (master) $ git...

How should I add new files when I already have multiple branches

git,branch,git-branch,branching-and-merging
We have recently started using GIT and it has worked out well, but we sometimes hits bumps that we don't know how to best solve. Right now we have multiple branches. master, develop and lots of feature branches (one or more per developer). Now we want to add a directory...

Getting the revision number of the end of a branch in WinCvs

version-control,branch,versioning,cvs,wincvs
I need a CVS command that given the name of a branch, it will give you the revision number of the last file in that branch. CVS Tree structure: (filename) | +--> 1.1-----(branch) | | | 1.1.1.1 | | | 1.1.1.2 | | | 1.1.1.3 | | 1.2 | |...

Git add branch on one single directory?

git,github,branch
I have a git repository on GitHub, with 3 different folders and only the master branch. How can i create a new branch on one single directory instead of all the three?

Create a branch from master with removed code

git,merge,branch
I wrote some code to implement two new features on a project, but I committed the changes to master. I now realize that this was a mistake, because one of the features is working well, and the other is not. I would like to keep the working feature code in...

Can I delete old git branches [duplicate]

git,branch,git-branch,git-merge
This question already has an answer here: Should I delete a branch after merging it? 2 answers I've merged my code into the master branch and all is good now. Code is production ready. I want to cleanup some of the old branches as there's really no need for...

Git - Make all files in a branch dirty

git,branch,phpstorm
I am using an IDE which allows me to deploy changes to a remote server as part of a commit. I am trying to find an easy way to deploy to the remote server all the changes I have made on a given feature after multiple commits all in the...

Switch remote branch in Git

git,branch
Is it possible to switch to different remote branch without cloning it? In remote I have multiple branches $ git branch -r origin/clay origin/HEAD -> origin/master origin/master origin/stand I cloned clay branch and working on it. Now I want to work on master branch. How can I switch to it?...

Netbeans git can't checkout local branch - Conflicts during checkout

git,netbeans,repository,branch,local
Here is my problem: I have cloned project from remote server (branches develop & master) I checked out develop after changes, commited & pushed to remote, everything is fine pull from remote while still in develop commit after pull switch or checkout to new created branch Page from develop -...

Checkout a complete Subversion tree excluding tags/ and branches/

bash,svn,version-control,cmd,branch
I'm working on a corporate source code tree that contains 100s of Maven sub-projects. Since each sub-project has its own layout of branches/ and tags/ sub-folders, the entire tree is laid out something like this: root/ some/intermediate/dirs/ project1/ branches/ ... tags/ ... trunk/ ... project2/ branches/ ... tags/ ... trunk/...

Using Eclipse with multiple branches

eclipse,git,branch
I am new to serious programming and just decided to start using Git and GitHub to manage my projects more effectively. I created a local repo, synchronised it with a remote on GitHub, and created new branch for testing new concept. All works fine, but when I click on this...

If : (Why is there no value assigned?)

python,variables,if-statement,branch,condition
Can anybody tell why is there no value assigned to begin after the condition at if begin: and just end with a colon instead? May I know what does it mean? if begin: begin = int(begin) end = int(raw_input("End:")) print "word[", begin,":",end,"] ", print word[begin:end] raw_input("\n\nPress the Enter Key to...