You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@buildr.apache.org by Anders_Asplund <aa...@hotmail.com> on 2008/10/10 09:09:10 UTC

buildr eclipse - bug?

Hi,

I'm trying to setup en existing eclipse project using buildr in a windows
environment. My project consists of several eclipse projects using project
dependencies to link them together.

Ex. Project A depends on project B:
http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B.png 

Since eclipse doesn't support hierarchical projects they have to be on the
same level but when I setup my buildfile I have to put them both in a
parent-project so that I can relate A from B. 

Ex. 
define 'my-app' do
 ...
  desc 'Project A'
  define 'A' do
  end
  desc 'Project B'
  define 'B' do
     compile.with projects('A')
  end
end

When I then try to run buildr eclipse to generate the eclipse artifacts the
project relation in eclipse becomes corrupt. Instead of pointing to /A it
points to /my-app-A.

Ex.
http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B-1.png 

When I look in the source code for eclipse.rb I can see that it adds 
project.id to the .classpath file. I can also se that it adds the project.id
in as the name of the project i the .project file. I've tried several
workarounds for this but haven't come up with a solution.


So my question is: Is there a solution for this or is it a bug?

/Anders
-- 
View this message in context: http://n2.nabble.com/buildr-eclipse---bug--tp1315442p1315442.html
Sent from the Apache Buildr - User mailing list archive at Nabble.com.


Re: buildr eclipse - bug?

Posted by Anders_Asplund <aa...@hotmail.com>.
Hi Alex,

I've opened an Jira issue but I can't find where to attach test case so I do
it here and link this thread in the 
http://issues.apache.org/jira/browse/BUILDR-169 jira issue .
http://n2.nabble.com/file/n1315616/buildr-bug.tar.gz buildr-bug.tar.gz 

I've also created a fix in my local eclipse.rb. I'm not a ruby developer so
you have to take the fix for what it is... :) I've marked my changes with
#******* Changed By Anders Asplund *********.
http://n2.nabble.com/file/n1315616/eclipse.rb eclipse.rb 


Thank you for your quick response!

/Anders


Alex Boisvert wrote:
> 
> It definitely sounds like a bug.   Can you open a Jira issue?
> 
> If you could provide a small test case (Buildfile + a couple of dummy
> source
> files) to reproduce it, I'm pretty sure we can fix it quickly.
> 
> alex
> 
> 
> On Fri, Oct 10, 2008 at 4:09 PM, Anders_Asplund
> <aa...@hotmail.com>wrote:
> 
>>
>> Hi,
>>
>> I'm trying to setup en existing eclipse project using buildr in a windows
>> environment. My project consists of several eclipse projects using
>> project
>> dependencies to link them together.
>>
>> Ex. Project A depends on project B:
>> http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B.png
>>
>> Since eclipse doesn't support hierarchical projects they have to be on
>> the
>> same level but when I setup my buildfile I have to put them both in a
>> parent-project so that I can relate A from B.
>>
>> Ex.
>> define 'my-app' do
>>  ...
>>  desc 'Project A'
>>  define 'A' do
>>  end
>>  desc 'Project B'
>>  define 'B' do
>>     compile.with projects('A')
>>  end
>> end
>>
>> When I then try to run buildr eclipse to generate the eclipse artifacts
>> the
>> project relation in eclipse becomes corrupt. Instead of pointing to /A it
>> points to /my-app-A.
>>
>> Ex.
>> http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B-1.png
>>
>> When I look in the source code for eclipse.rb I can see that it adds
>> project.id to the .classpath file. I can also se that it adds the
>> project.id
>> in as the name of the project i the .project file. I've tried several
>> workarounds for this but haven't come up with a solution.
>>
>>
>> So my question is: Is there a solution for this or is it a bug?
>>
>> /Anders
>> --
>> View this message in context:
>> http://n2.nabble.com/buildr-eclipse---bug--tp1315442p1315442.html
>> Sent from the Apache Buildr - User mailing list archive at Nabble.com.
>>
>>
> 
> 

-- 
View this message in context: http://n2.nabble.com/buildr-eclipse---bug--tp1315442p1315616.html
Sent from the Apache Buildr - User mailing list archive at Nabble.com.


Re: buildr eclipse - bug?

Posted by Alex Boisvert <bo...@intalio.com>.
It definitely sounds like a bug.   Can you open a Jira issue?

If you could provide a small test case (Buildfile + a couple of dummy source
files) to reproduce it, I'm pretty sure we can fix it quickly.

alex


On Fri, Oct 10, 2008 at 4:09 PM, Anders_Asplund <aa...@hotmail.com>wrote:

>
> Hi,
>
> I'm trying to setup en existing eclipse project using buildr in a windows
> environment. My project consists of several eclipse projects using project
> dependencies to link them together.
>
> Ex. Project A depends on project B:
> http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B.png
>
> Since eclipse doesn't support hierarchical projects they have to be on the
> same level but when I setup my buildfile I have to put them both in a
> parent-project so that I can relate A from B.
>
> Ex.
> define 'my-app' do
>  ...
>  desc 'Project A'
>  define 'A' do
>  end
>  desc 'Project B'
>  define 'B' do
>     compile.with projects('A')
>  end
> end
>
> When I then try to run buildr eclipse to generate the eclipse artifacts the
> project relation in eclipse becomes corrupt. Instead of pointing to /A it
> points to /my-app-A.
>
> Ex.
> http://n2.nabble.com/file/n1315442/Screenshot-Properties%2Bfor%2BB%2B-1.png
>
> When I look in the source code for eclipse.rb I can see that it adds
> project.id to the .classpath file. I can also se that it adds the
> project.id
> in as the name of the project i the .project file. I've tried several
> workarounds for this but haven't come up with a solution.
>
>
> So my question is: Is there a solution for this or is it a bug?
>
> /Anders
> --
> View this message in context:
> http://n2.nabble.com/buildr-eclipse---bug--tp1315442p1315442.html
> Sent from the Apache Buildr - User mailing list archive at Nabble.com.
>
>