Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 339115 - [server] Provide REST API for git push
Summary: [server] Provide REST API for git push
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 0.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 0.2   Edit
Assignee: Tomasz Zarna CLA
QA Contact:
URL: http://www.kernel.org/pub/software/sc...
Whiteboard:
Keywords:
Depends on: 339354
Blocks: 339722 343153
  Show dependency tree
 
Reported: 2011-03-07 11:10 EST by Tomasz Zarna CLA
Modified: 2011-09-01 11:43 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tomasz Zarna CLA 2011-03-07 11:10:56 EST
We're going to need REST API for git push (pushing changes to a remote repository).
Comment 1 Tomasz Zarna CLA 2011-03-07 11:11:34 EST
We should be able to push tags as well (--tags option).
Comment 2 Tomasz Zarna CLA 2011-04-18 08:44:57 EDT
Pushing content of HEAD to given remote branch ("git push origin HEAD:master") can be now accomplished[1] by POSTing on the remote branch URI with PushSrcRef[2] = HEAD in request body.

Leaving the bug open to add more tests and support for pushing tags.

[1] http://git.eclipse.org/c/e4/org.eclipse.orion.server.git/commit/?id=2eaff1f5b4040f868f71f8d10105e04a1204b56e 
[2] org.eclipse.orion.server.git.GitConstants.KEY_PUSH_SRC_REF
Comment 3 Szymon Brandys CLA 2011-04-19 10:25:35 EDT
There is an issue with the current shape of it. When there are changes in the remote tracking branch to merge, doing Git Push will return 200, however the operation fails. Tomasz, you said there is a separate bug for it, could you link it to the bug? We should fix it ASAP.
Comment 4 Tomasz Zarna CLA 2011-04-21 04:45:25 EDT
(In reply to comment #3)
> There is an issue with the current shape of it. When there are changes in the
> remote tracking branch to merge, doing Git Push will return 200, however the
> operation fails. Tomasz, you said there is a separate bug for it, could you link
> it to the bug? 

It was bug 343153.
Comment 5 Tomasz Zarna CLA 2011-04-21 05:23:31 EDT
(In reply to comment #2)
> Leaving the bug open to add more tests 

Filed bug 343496, most probably not for 0.2M7.

> and support for pushing tags.

Fixed with http://git.eclipse.org/c/e4/org.eclipse.orion.server.git/commit/?id=bab16d9960f9667d81b12f8e62d59d4ede5db6a6. Use org.eclipse.orion.server.git.GitConstants.KEY_PUSH_TAGS set to "true".