buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jesus M. Rodriguez" <>
Subject Re: customizing .classpath generation for eclipse
Date Sun, 18 Apr 2010 13:33:00 GMT
Well it's not really weird behavior, the problem is in eclipse we need
the src/main/resources to go to target/classes instead of target/resources.
IIRC it's related to the persistence.xml location since it needs to be
where my entity classes live.

I was actually able to post process the .classpath quite simply by
doing the following:

task :eclipse do
  puts "Fixing eclipse .classpath"
  text =".classpath")
  tmp ="tmp", "w")
  tmp.write(text.gsub(/output="target\/resources"/, ""))
  FileUtils.copy("tmp", ".classpath")

This works great, it does the default eclipse task then it runs my code block.


On Fri, Feb 26, 2010 at 11:58 AM, Chetan Sarva <> wrote:
> What sort of weird behavior? I've noticed buildr is sometimes confused
> about the current compilation state and acts a bit strangely but a
> clean compile generally fixes it.
> On Thu, Feb 25, 2010 at 7:58 PM, Jesus M. Rodriguez <> wrote:
>> Is there a way to have buildr generate the .classpath using a custom
>> output target? By default it pulls in target/classes, we've had
>> problems with eclipse and buildr target being the same (i.e. switching
>> between the two causes weird behavior).
>> Sincerely,
>> jesus rodriguez

View raw message