Problem regarding not stashing unstaged/untracked changes as in ADStudio 14 Dev 10.
Assume we have a repo in which we create a new file called new_file.txt.
Now we add this new file to be tracked (Version Control > Add), and after that we open the file and add a new text of line inside it, "new line here", and save it. We go now in the Repo Window and click Slash. The Stash window opens, however the extra warning message is no longer shown as in issue #8532, even through there exist some untracked changes, the added new line. Clicking the Stash Changes button and then applying the newly created stash looses the added new line.
As mentioned in issue #8352 untracked files are not the same as unstaged files. Once you do Version Control -> Add, the new file is staged and it can be stashed.
In the latest build, I am able to stash the newly added file and restore the change by applying the stash. Please verify the issue in the latest build - may be build after #31393.
May be fixed due to recent changes in Stash feature.
May be fixed due to recent changes in Stash feature.
Verified using ADStudio 14 Dev 13 from 22nd of February, I'm not sure, but I think it should include the mentioned recent changes; however the problem still appears.
Restating the scenario:
* Assume we have a repo in which we create a new file called new_file.txt.
* Now we add this new file to be tracked (Version Control > Add), and after that we open the file and add a new line of text inside it, "new line here", and save it.
* Going inside the Commit window we see that there are two changes: the staged "Added" new_file, and the unstaged "Modified" new_file.
* We go now in the Repository Browser window and click Slash. The Stash window opens. Clicking the Stash Changes button and then applying the newly created stash looses the added new line. In other words the second change (unstaged "Modified" new_file) is lost.
The problem seems to be generated by the Stash action, because if creating the stash via git stash
and then applying it via ADS Git, everything works as expected.
Verified using ADStudio 14 Dev 13 from 22nd of February, I'm not sure, but I think it should include the mentioned recent changes; however the problem still appears.
Restating the scenario:
* Assume we have a repo in which we create a new file called new_file.txt.
* Now we add this new file to be tracked (Version Control > Add), and after that we open the file and add a new line of text inside it, "new line here", and save it.
* Going inside the Commit window we see that there are two changes: the staged "Added" new_file, and the unstaged "Modified" new_file.
* We go now in the Repository Browser window and click Slash. The Stash window opens. Clicking the Stash Changes button and then applying the newly created stash looses the added new line. In other words the second change (unstaged "Modified" new_file) is lost.
The problem seems to be generated by the Stash action, because if creating the stash via git stash
and then applying it via ADS Git, everything works as expected.
Thanks for posting me the details. I kind of overlooked your test case.
This issue seems to be coming from the jGit api. I have posted a bug for this issue,
https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396
We will wait for the responses from the jGit community.
Thanks for posting me the details. I kind of overlooked your test case.
This issue seems to be coming from the jGit api. I have posted a bug for this issue,
https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396
We will wait for the responses from the jGit community.
Will try the following patch
https://git.eclipse.org/r/11757
Reference:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396#c1
Will try the following patch
https://git.eclipse.org/r/11757
Reference:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396#c1
Applied patch available at https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396#c1, and issue no longer happens.
Applied patch available at https://bugs.eclipse.org/bugs/show_bug.cgi?id=402396#c1, and issue no longer happens.
Verified using ADStudio 14 Dev 40, the changes after adding the new file are now retained. ADS behaves in the given scenario like calling git stash
and then git stash apply --index
.
Closed.
Verified using ADStudio 14 Dev 40, the changes after adding the new file are now retained. ADS behaves in the given scenario like calling git stash
and then git stash apply --index
.
Closed.
Issue #8353 |
Closed |
Fixed |
Resolved |
Completion |
No due date |
Fixed Build 31905 |
No time estimate |
1 issue link |
relates to #13187
Issue #13187Upgrade JGit to latest version |
As mentioned in issue #8352 untracked files are not the same as unstaged files. Once you do Version Control -> Add, the new file is staged and it can be stashed.
In the latest build, I am able to stash the newly added file and restore the change by applying the stash. Please verify the issue in the latest build - may be build after #31393.