Hi,
On Thu, Mar 7, 2013 at 9:22 AM, Vincent Massol <vincent(a)massol.net>
wrote:
On Mar 6, 2013, at 6:16 PM, Jeremie BOUSQUET <
jeremie.bousquet(a)gmail.com>
wrote:
Hi,
@Vincent : I agree with all your points, my feedback was more on that
these
points may not be clear for contributors at first
(at least, it wasn't
for
me).
We need to put all information on
contrib.xwiki.org so if you think
something is missing there, maybe you could add it?
My only little worry is that maybe it does not
require the same level
of knowledge to merely create and publish a simple extension on
xwiki.org,
> and to develop a maven module for it and release it to Nexus staging
from
github,
though it'd be better to have all extensions in a maven
repository
(for flavors/bundles for example).
Sure it doesn't! This is why
contrib.xwiki.org provides explanations.
> Additionnally, it seems that with the sample pom provided (for xar), I
> always get the following error when trying to release:
>
> [INFO] --- maven-enforcer-plugin:1.1:enforce
(enforce-javadoc-exists)
@
> xwiki-macro-tabs ---
> [WARNING] Rule 0:
org.apache.maven.plugins.enforcer.EvaluateBeanshell
failed
with message:
Couldn't evaluate condition: ("xar" != "jar") ||
("xar" == "jar" &&
new
java.io.File("C:\PRIVATE\tabs-macro\target\checkout\target/xwiki-macro-tabs-1.0.1-SNAPSHOT-javadoc.jar")
.exists())
The rule we have in the commons pom is:
<condition>("${project.packaging}" !=
"jar") ||
("${project.packaging}" == "jar" && new
java.io.File("${project.build.directory}/${project.build.finalName}-javadoc.jar").exists())</condition>
so I guess replacing all "\" with "/" in ${project.build.directory}
should
work.
I don`t know all the details, but that looks like java (or groovy), so I
guess that, for windows, instead of "\", you should use "\\" or else
it
will try to escape stuff.
Main problem is that maven exposes system paths inside properties without
caring about them being later used from java or other language, which is
understandable though pretty annoying sometimes.
Also, why not use java.io.File.separator instead of the manual "/" or
"\\"?
For sure, I should replace "${file.separator}" by '/' to be sure. But
as
separator that causes problems in java is 100% of time single backslash
'\', I'm not sure it would bring anything better.