Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 349299

Summary: [server] Provide REST API for git rm
Product: [ECD] Orion Reporter: Tomasz Zarna <tomasz.zarna>
Component: GitAssignee: Project Inbox <orion.git-inbox>
Status: RESOLVED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: janikpiotrek, Szymon.Brandys
Version: 0.2   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Tomasz Zarna CLA 2011-06-14 05:59:12 EDT
We're going to need REST API for git rm to remove files from the index.
Comment 1 Tomasz Zarna CLA 2011-06-14 06:01:14 EDT
This could be implemented as DELETE on IndexLocation of a file: /gitapi/index/file/{projectId}/{pathToFile}.
Comment 2 Tomasz Zarna CLA 2011-06-14 11:50:55 EDT
For now, staging file deletions is done by doing "git add -u {pattern}" in GitIndexHandlerV1.handlePut(...)[1]. This seems to work fine, but there are at least two drawbacks:
* "git add" is called twice[1]
* the file needs to be deleted first and then staged with "git add -u" to be removed from the index. With "git rm" in place, the former can be skipped[2]

[1] org.eclipse.orion.server.git.servlets.GitIndexHandlerV1.handlePut(HttpServletRequest, HttpServletResponse, Repository, String)
[2] see org.eclipse.orion.server.tests.servlets.git.GitStatusTest.testStatusRemoved() for details
Comment 3 John Arthorne CLA 2015-05-05 15:49:30 EDT
Closing as part of a mass clean up of inactive bugs. Please reopen if this problem still occurs or is relevant to you. For more details see:


https://dev.eclipse.org/mhonarc/lists/orion-dev/msg03444.html
Comment 4 John Arthorne CLA 2015-05-05 16:02:26 EDT
Closing as part of a mass clean up of inactive bugs. Please reopen if this problem still occurs or is relevant to you. For more details see:


https://dev.eclipse.org/mhonarc/lists/orion-dev/msg03444.html