Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [egit-dev] test m2e build with OSGi support

2010/1/9 Igor Fedorenko <ifedorenko@xxxxxxxxxxxx>
Matthias Sohn wrote:

I tried  using freshly installed 3.6 M4 on Windows XP using Sun VM 1.6.0_17-b04.
Project files have proper natures and builders and Eclipse build for all projects succeeds.

What doesn't work is Export Feature (right click) on project org.eclipse.egit-feature it seems

I did not really think about export from IDE, to be honest. I always use
Tycho on cli for my packaging needs (and PDE export was not very
reliable for me in the past).

How do I start cli for embedded Maven coming with m2e ?

Now this doesn't fail anymore but the org.eclipse.jgit.jar contains class files under target/classes instead under root
(for egit plugins this is not the case). Don't know how this comes.

... <snip> ...

This works for me on Linux and I just checked it works in my winxp vm
both with e351 and e36m4. To narrow down the problem, can you check few
things for me (in no particular order)...

* can you confirm this happens with fresh eclipse install after
importing jgit/egit into a fresh workspace? if not, can you try with
fresh eclipse install and workspace?

I tried again with fresh eclipse install 3.6 M4 and a fresh workspace and now it succeeds :-)
No idea what I did differently this time ...
 

* any other interesting messages in eclipse .log of the test workspace?
Especially things like bundle activation failures and bundle
classloading timeouts.

no, nothing this time
 
* can you check Plug-ins tab of the Eclipse Application launch
configuration. it should say "Launch with all workspace and enabled
target platform plugins".

yes that's what it says
 
* does

C:/data/ide/helios/.metadata/.plugins/org.eclipse.pde.core/Eclipse
Application/dev.properties contain entries for jgit projects?

yes, it contains

org.eclipse.jgit.console=target/classes
org.eclipse.jgit.ui=target/classes
org.eclipse.egit.core=target/classes
org.eclipse.jgit.junit=target/classes
org.eclipse.egit.core.test=target/classes
org.eclipse.jgit=target/classes
org.eclipse.egit.ui=target/classes
@ignoredot@=tru
 
* can you confirm you see the problem with up-todate copies of
egit.eclipse.org/jgit.git and egit.eclipse.org/egit.git?


I tried with freshly cloned jgit and egit (no changes between last try and this time)

There is some git support in m2e. I never tried it myself but heard it was not very good. From what I know, it uses some old version of maven-scm framework, which delegates to cli git to do actual work. We plan to eventually replace it with EGit integration, but, frankly, EGit is not ready yet.


Aah ok, I thought, maybe this is already using JGit. With m2e 0.9.8 git cloning via
"Import Maven Projects from SCM" simply worked.

I carefully compared what m2e import touched in freshly cloned jgit and egit repo and found
some places where I didn't expect m2e's behavior. Here the complete script of my test,
I marked problems by enclosing them in >>>>>>> ... <<<<<<<< :

----------------------------------------------------------------------------------------------
- install Eclipse SDK 3.6 M4
- point eclipse.ini parameter -vm to Sun JDK 1.6.0_17-b04
- restart Eclipse
- new Eclipse workspace
- install m2e from [1] (all features)
- restart Eclipse
- Help > About > Installation Details > Configuration -> eclipse-config.txt
- delete local m2 repository
- ensure core.hideDotFiles = false
    d029788@WDFN00200862A /c/data/ide/helios
    $ git config --get core.hideDotFiles
    false
- clone fresh jgit into Eclipse workspace
    d029788@WDFN00200862A /c/data/ide/helios
    $ git clone git://egit.eclipse.org/jgit.git
- HEAD at commit 3650a945a3b972f8208590ea7d98b2d733e6d68f
- clone fresh egit into workspace
    d029788@WDFN00200862A /c/data/ide/helios
    $ git clone git://egit.eclipse.org/egit.git
- HEAD at commit 69ba907350d1828443a3c1544f23f5ae89b9022b
- File > Import > Maven > Existing Maven Projects, select Eclipse workspace as root directory, finish
  ... waiting 7 min (over 2 MBit DSL link)

- copy console log to console.log
- copy .log

- egit projects with red crosses:
    org.eclipse.egit.core
    org.eclipse.egit.core.test
    org.eclipse.egit.ui have red crosses
- PDE Tools > Update Classpath fixes them -> no build errors

>>>>>>>
- git diff reveals that m2e touched the checked in .settings/org.eclipse.jdt.core.prefs
  for all projects (both jgit and egit) :
  - org.eclipse.jdt.core.compiler.problem.forbiddenReference changed from error to warning
  - all line endings changed from unix to windows
- for jgit
  - generated .project files have PDE and maven nature and corresponding builders, windows line endings
  - generated .classpath files look ok, unix line endings
- for egit
  - .project files: maven nature and builder added, line endings changed from unix to windows
  - for org.eclipse.egit java nature and builder added (project is branding plugin and
    has no Java sources)
  - .classpath files output switched from bin to target/classes
<<<<<<<<

- create run configuration to run EGit and save it
- Plug-ins tab of the Eclipse Application launch configuration says
  "Launch with all workspace and enabled target platform plugins".
- error log has no new entries
- start run configuration :-) EGit works in started workbench
  - test sequence:
    create Java project
    share it with Git
    add to version control
    commit
    show in resource history
    -> all work :-)

- right click on project org.eclipse.egit-feature > Export > Plugin Development > Deployable Features
- this time this also works
>>>>>>>
- but jgit plugin contains class files under target/classes instead under root (for egit plugins this is not the case)
<<<<<<<<

[1] http://repository.sonatype.org/content/sites/forge-sites/m2e/m2eclipse-tycho-201001081647/
----------------------------------------------------------------------------------------------

--
Matthias

Back to the top