Hi,
I am evaluating jira + stash integration. I have made a feature branch dirrectly from JIRA then i commit something into that branch. I wish that stash detected those changes inside that branch as changes on that specifix issue that i created the branch for so i don't have a branch feature/MYISSUE-10 bla bla then when i commit i have to put MYISSUE-10 in the commit message.
I know that it would not make sense in all cases but maybe in this spceific case where a branch has an known issue name then it could detect it.
Anyone has a simmilar request ?
/donnib
Community moderators have prevented the ability to post new answers.
The main reason why Stash doesn't consider the branch name when linking commits to issues is that branches in git are transient.
In git, a branch is simply a pointer to a commit. Any commit that is an ancestor of that commit is considered to be 'on' the branch. This means that a commit can be on multiple branches at the same time and also that the set of branches a commit is on can change over time as branches are added and deleted.
If Stash would consider the branch name when matching a commit to an issue, it would all depend on when Stash first sees the commit and what branch(es) it is on at that time. If you delete the branch and Stash would ever need to rebuild its commit -> issue mapping, all hints would be gone and it would not be able to map them anymore.
@Michael thank you very much for the thoroughly explanation. That makes totally sense why it is like that.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The assumption that branches are transient is a question of workflow, not an innate facet of git. We never remove branches from git, as doing so destroys history. In our environment, branches provide a perfect mapping.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, this would be a good imprvement.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Jira 6.1 + Stash 2.8 should have a feature to create branch for JIRA issue. See https://answers.atlassian.com/questions/207287/create-a-git-stash-branch-from-jira
Edit
Or maybe I am wrong. Based on last comment here you wont get what your after http://blogs.atlassian.com/2013/10/stash-28-git-branch-workflows/
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Community moderators have prevented the ability to post new answers.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.