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

Bug 339310

Summary: Option to make each project or workspace a git repository
Product: [ECD] Orion Reporter: John Arthorne <john.arthorne>
Component: ClientAssignee: John Arthorne <john.arthorne>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: bokowski, Szymon.Brandys
Version: 0.2   
Target Milestone: 0.2   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description John Arthorne CLA 2011-03-08 22:40:10 EST
Without push/pull functionality, and no file system access for users, there is no way to showcase our git functionality on orion.eclipse.org for M6. Boris suggested a server setting so that all projects are automatically inside a repository.
Comment 1 John Arthorne CLA 2011-03-08 22:44:41 EST
It is a bit of a hack, but I have implemented this inside GitFileDecorator.java. See method initGitRepository. It only works if the following server configuration properties are set:

orion.file.layout=userTree
orion.project.defaultSCM=git

What it does is create one repository *per user* on the server. Since in the userTree layout, each user's data is inside a unique folder, this reduces the number of repositories and achieves the same effect.

I have played around with this, and it is a bit goofy but at least showcases the git functionality. For example I can stage/commit changes, and then compare future edits to what I committed. With the added ability to browse and replace with arbitrary revisions it would be realy cool... something to consider for M7.
Comment 2 John Arthorne CLA 2011-03-08 23:19:19 EST
Change released.
Comment 3 Szymon Brandys CLA 2011-03-09 06:42:54 EST
(In reply to comment #2)
> Change released.

I just made a minor fix. The Git node was not included in the JSON response for POST /workspace/[workspaceId], when the newly introduced configuration properties are set to create repos.
Comment 4 Boris Bokowski CLA 2011-03-09 07:31:37 EST
(In reply to comment #1)
> What it does is create one repository *per user* on the server. 

A Git user would typically expect one repository per project (top level folder). Were you concerned about server load? I don't think creating one repository per project would mean more load compared to one repository per user.