Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "RAP/Git"

< RAP
(Commit messages)
(Add Gerrit, minor restructuring)
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
== Repositories ==
 
== Repositories ==
  
=== Common Structure ===
+
All RAP source code is hosted in [[Git]] repositories. We use [[Gerrit]] to review changes by committers and contributors.
  
We've agreed on a common structure for all our Git repositories:
+
=== RAP ===
  
; bundles/
+
This repository contains the entire source code of the RAP platform (a.k.a. the runtime).
: all bundle projects
+
; features/
+
: feature projects
+
; releng/
+
: projects for release engineering
+
; tests/
+
: unit test projects
+
  
=== RAP Runtime ===
+
* Web interface: {{Git|rap|org.eclipse.rap.git}}
 +
* Git URL (use to clone the repository): git://git.eclipse.org/gitroot/rap/org.eclipse.rap.git
 +
* Gerrit URL (use to push changes): ssh://username@git.eclipse.org:29418/rap/org.eclipse.rap.git
  
There will be one repository for RAP itself (a.k.a. the runtime):
+
Note: The project `org.apache.tomcat` that used to be in runtime.rwt.test in CVS has been moved into its own Git repository {{Git|rap|org.apache.tomcat.git}}. If possible this project should be reused from the Gemini project (or from Orbit) in the future.
 
+
* {{Git|rap|org.eclipse.rap.git}}
+
* git://git.eclipse.org/gitroot/rap/org.eclipse.rap.git (read-only)
+
* ssh://COMMITTER_ID@git.eclipse.org/gitroot/rap/org.eclipse.rap.git
+
 
+
Note: The project 'org.apache.tomcat' that used to be in runtime.rwt.test in CVS has been moved into its own Git repository {{Git|rap|org.apache.tomcat.git}}. If possible this project should be reused from the Gemini project (or from Orbit) in the future.
+
  
 
=== RAP Tools ===
 
=== RAP Tools ===
  
.. and one repository for the RAP Tools:
+
This repository contains the code of the Eclipse tools for RAP.
  
* {{Git|rap|org.eclipse.rap.tools.git}}
+
* Web interface: {{Git|rap|org.eclipse.rap.tools.git}}
* git://git.eclipse.org/gitroot/rap/org.eclipse.rap.tools.git (read-only)
+
* Git URL (use to clone the repository): git://git.eclipse.org/gitroot/rap/org.eclipse.rap.tools.git
* ssh://COMMITTER_ID@git.eclipse.org/gitroot/rap/org.eclipse.rap.tools.git
+
* Gerrit URL (use to push changes): ssh://username@git.eclipse.org:29418/rap/org.eclipse.rap.tools.git
  
 
=== RAP Incubator ===
 
=== RAP Incubator ===
Line 36: Line 25:
 
The RAP Incubator project is partitioned into components. Every component has its own repository:
 
The RAP Incubator project is partitioned into components. Every component has its own repository:
  
* [http://git.eclipse.org/c/rap/incubator list of incubator repositories]
+
* Web interface: [http://git.eclipse.org/c/rap/incubator list of incubator repositories]
* git://git.eclipse.org/gitroot/rap/incubator/org.eclipse.rap.incubator.COMPONENT.git (read-only)
+
* Git URL (use to clone the repository): git://git.eclipse.org/gitroot/rap/incubator/org.eclipse.rap.incubator.COMPONENT.git (read-only)
* ssh://COMMITTER_ID@git.eclipse.org/gitroot/rap/incubator/org.eclipse.rap.incubator.COMPONENT.git
+
* Committer URL (read/write access): ssh://COMMITTER_ID@git.eclipse.org/gitroot/rap/incubator/org.eclipse.rap.incubator.COMPONENT.git
  
== Working with Git ==
+
== Common Repository Structure ==
 +
 
 +
We've agreed on a common structure for all our Git repositories:
 +
 
 +
; bundles/
 +
: all bundle projects
 +
; features/
 +
: feature projects
 +
; releng/
 +
: projects for release engineering
 +
; tests/
 +
: unit test projects
 +
; examples/
 +
: for bundles containing exemplary applications and demo code
 +
 
 +
== Git Practices ==
 +
 
 +
=== Commits ===
 +
 
 +
* Make commits of logical units, do not mix different topics in a single commit.
 +
* When splitting up bigger tasks into logical units, every single commit should produce a consistent version, i.e. the test suite must pass after every commit.
 +
* Make sure your commit does not introduce any unnecessary whitespace.
 +
* Make sure your commit does not include any commented code, sysouts, etc.
 +
* Make sure that the tests are included together with the fix.
  
 
=== Commit messages ===
 
=== Commit messages ===
Line 68: Line 80:
 
   
 
   
 
  - Use a hanging indent
 
  - Use a hanging indent
 +
 +
Some further advice can be found [http://www.kernel.org/pub/software/scm/git/docs/v1.7.6.5/SubmittingPatches here].
 +
 +
* The commit message should be understandable when reading through the commit log. That's why it should be simple and should make sense also without context.
 +
 +
* The body should explain the problem and the solution. It should also point out why the solution has been chosen, and what other alternatives have been considered, but discarded.
 +
 +
* The explanation should be understandable without external resources. It's good to provide the URL to a discussion or a bug, but the important points should also be summarized in the commit message.
 +
 +
=== Committing patches ===
 +
 +
* Make use the Author field in the commit is set to the original author.
 +
 +
* When committing a patch from someone else, add a "Signed-off-by: Committer Name <committer@email>" line to the commit message, to confirm that you agree with the patch and made sure the patch is IP clean.
  
 
== Resources ==
 
== Resources ==
  
* [[Git]] - general introduction to git at Eclipse
+
* [[Git]] at Eclipse
 +
* [[Gerrit]] at Eclipse
  
 
[[Category:RAP]]
 
[[Category:RAP]]

Revision as of 07:29, 19 December 2013

Repositories

All RAP source code is hosted in Git repositories. We use Gerrit to review changes by committers and contributors.

RAP

This repository contains the entire source code of the RAP platform (a.k.a. the runtime).

Note: The project `org.apache.tomcat` that used to be in runtime.rwt.test in CVS has been moved into its own Git repository org.apache.tomcat.git (browse, stats, fork on OrionHub) . If possible this project should be reused from the Gemini project (or from Orbit) in the future.

RAP Tools

This repository contains the code of the Eclipse tools for RAP.

RAP Incubator

The RAP Incubator project is partitioned into components. Every component has its own repository:

Common Repository Structure

We've agreed on a common structure for all our Git repositories:

bundles/
all bundle projects
features/
feature projects
releng/
projects for release engineering
tests/
unit test projects
examples/
for bundles containing exemplary applications and demo code

Git Practices

Commits

  • Make commits of logical units, do not mix different topics in a single commit.
  • When splitting up bigger tasks into logical units, every single commit should produce a consistent version, i.e. the test suite must pass after every commit.
  • Make sure your commit does not introduce any unnecessary whitespace.
  • Make sure your commit does not include any commented code, sysouts, etc.
  • Make sure that the tests are included together with the fix.

Commit messages

Commit messages should follow the recommended format described in this article:

Capitalized, short (50 chars or less) summary

More detailed explanatory text, if necessary.  Wrap it to about 72
characters or so.  In some contexts, the first line is treated as the
subject of an email and the rest of the text as the body.  The blank
line separating the summary from the body is critical (unless you omit
the body entirely); tools like rebase can get confused if you run the
two together.

Write your commit message in the present tense: "Fix bug" and not "Fixed
bug."  This convention matches up with commit messages generated by
commands like git merge and git revert.

Further paragraphs come after blank lines.

- Bullet points are okay, too

- Typically a hyphen or asterisk is used for the bullet, preceded by a
  single space, with blank lines in between, but conventions vary here

- Use a hanging indent

Some further advice can be found here.

  • The commit message should be understandable when reading through the commit log. That's why it should be simple and should make sense also without context.
  • The body should explain the problem and the solution. It should also point out why the solution has been chosen, and what other alternatives have been considered, but discarded.
  • The explanation should be understandable without external resources. It's good to provide the URL to a discussion or a bug, but the important points should also be summarized in the commit message.

Committing patches

  • Make use the Author field in the commit is set to the original author.
  • When committing a patch from someone else, add a "Signed-off-by: Committer Name <committer@email>" line to the commit message, to confirm that you agree with the patch and made sure the patch is IP clean.

Resources

Back to the top