As I stated at BUILDR-493, adding javadocpath reference to .classpath should be similar to adding sourcepath reference to .classpath which has been done at the linked issue. Making a javadoc_artifact method similar to sources_artifact method at artifact.rb may be the starting point.
Nikos On Mon, Aug 23, 2010 at 6:39 PM, Antoine Toulme <anto...@lunar-ocean.com> wrote: > That lines asks if the object lib_artifact has a method, or implements > method_missing in a way that it responds to sources_artifact. > > On Mon, Aug 23, 2010 at 01:34, Nikos Maris <nickm...@gmail.com> wrote: > >> I don't plan to commit but I would like to find what the following line >> does: >> file: ide/eclipse.rb >> class: ClasspathEntryWriter >> method: var(libs) >> line: if lib_artifact.respond_to? :sources_artifact >> >> Nikos >> >> On Mon, Aug 23, 2010 at 10:54 AM, Nikos Maris <nickm...@gmail.com> wrote: >> > Before post processing eclipse, I want to deal with another issue >> > (BUILDR-494), By the way, when a library is not in any maven repo and >> > I use "download artifact", the generated classpath file includes >> > sourcepath. Can you point me to the source code that does that? >> > >> > ---------------------------------- >> > Nikos Maris >> > Software Engineer >> > IMC Technologies SA >> > www.imc.com.gr >> > >> > On Mon, Aug 23, 2010 at 3:10 AM, Jesus M. Rodriguez <jmro...@gmail.com> >> wrote: >> >> Here's what I did to patch our .classpath to remove the >> target/resources. >> >> I tried depending on the eclipse task but that didn't seem to work. >> >> But defining the >> >> :eclipse task in my buildfile seemed to work: >> >> >> >> task :eclipse do >> >> puts "Fixing eclipse .classpath" >> >> text = File.read(".classpath") >> >> tmp = File.new("tmp", "w") >> >> tmp.write(text.gsub(/output="target\/resources"/, "")) >> >> tmp.close() >> >> FileUtils.copy("tmp", ".classpath") >> >> File.delete("tmp") >> >> >> >> # make the gettext output dir to silence eclipse errors >> >> mkdir_p("target/generated-source") >> >> end >> >> >> >> This causes buildr to generate the .classpath as normal, then we post >> >> process it. >> >> It works great. Maybe you can do something similar. >> >> >> >> jesus >> >> >> >> On Sun, Aug 22, 2010 at 2:16 PM, Antoine Toulme < >> anto...@lunar-ocean.com> wrote: >> >>> This is not supported right now - if you have a small scale example of >> what >> >>> you need, feel free to open a bug. >> >>> >> >>> You may be able to change M2_REPO to map to a relative path. I'd need >> to >> >>> experiment a bit on that. >> >>> >> >>> On Sun, Aug 22, 2010 at 11:02, Nikos Maris <nickm...@gmail.com> wrote: >> >>> >> >>>> Hi all, >> >>>> >> >>>> Could you tell me how can I generate .classpath file with >> >>>> javadocpath, or who to ask? Although I have javadoc in JARs, the >> >>>> following code does not produce javadocpath. >> >>>> >> >>>> eclipse.natures 'org.eclipse.jdt.core.javanature' >> >>>> eclipse.builders 'org.eclipse.jdt.core.javabuilder' >> >>>> eclipse.classpath_containers >> >>>> >> >>>> >> 'org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6' >> >>>> compile.from('src').into('bin') # adds src to classpath >> >>>> (default >> >>>> project hierarchy is sources=src/main/java and target=target/classes) >> >>>> desc 'Unbound M2_REPO from .classpath file to a relative path' >> >>>> task :geneclipse => :eclipse do >> >>>> begin >> >>>> unbounded = >> File.read(".classpath").gsub(/M2_REPO/, >> >>>> File.join('lib','m2')).gsub(/kind="var"/, 'kind="lib"') >> >>>> File.open(".classpath", "w") {|file| file.puts >> >>>> unbounded} >> >>>> end >> >>>> end >> >>>> >> >>>> ---------------------------------- >> >>>> Nikos Maris >> >>>> Software Engineer >> >>>> IMC Technologies SA >> >>>> www.imc.com.gr >> >>>> >> >>> >> >> >> > >> >