Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

archetypes are not available via maven central #145

Open
jjYBdx4IL opened this issue Nov 4, 2014 · 13 comments
Open

archetypes are not available via maven central #145

jjYBdx4IL opened this issue Nov 4, 2014 · 13 comments

Comments

@jjYBdx4IL
Copy link

Please deploy them there. thanks!

http://stackoverflow.com/questions/8167749/use-maven-archetype-nar-exec-to-generate-project

@dscho
Copy link
Member

dscho commented Nov 4, 2014

@jjYBdx4IL please note that a thorough, well-described report is always appreciated much more than a terse two liner.

The StackOverflow question you reference predates the rename to nar-maven-plugin – which is on Maven Central for some time now.

Now, it is not obvious what needs to be done to support those archetypes. This poses an excellent opportunity to make up for the unnecessarily terse report and research what it takes to support the archetypes via Maven Central, and provide an informed, detailed report as a comment here.

Alternatively, you can always ask for customer support on the mailing list (you might want to offer a monetary incentive if you want to go that route).

@ctrueden
Copy link
Contributor

ctrueden commented Nov 5, 2014

FWIW, @dscho was looking into archetypes a bit the other day, and ended up creating three new repositories based on @duns's previous work:

Still not deployed to Central yet, though; I'm reopening this issue until they are.

@ctrueden ctrueden reopened this Nov 5, 2014
@jjYBdx4IL
Copy link
Author

Tanks a lot! I was a bit confused because the docs listed them.

@jjYBdx4IL
Copy link
Author

I found an example athttp://www.openimaj.org/tutorial/getting-started-with-openimaj-using-maven.html :

mvn -DarchetypeCatalog=http://maven.openimaj.org/archetype-catalog.xml archetype:generate

Though it would be nicer to have the archetypes available directly from maven central.

@dscho
Copy link
Member

dscho commented Nov 20, 2014

Though it would be nicer to have the archetypes available directly from maven central.

In the meantime, I have found out that Nexus does this automatically. All we would need is to adjust https://github.com/maven-nar/maven-archetype-nar-exec, https://github.com/maven-nar/maven-archetype-nar-lib and https://github.com/maven-nar/maven-archetype-nar-jni and deploy them. However, researching this much was not my duty, so I feel I over-contributed already to this ticket.

@dscho
Copy link
Member

dscho commented Dec 9, 2014

@jjYBdx4IL I kind of expected you to take it from there... do you want the archetypes on Nexus or not?

@dproteus13
Copy link

sorry for the churn above, I was still learning this issue tracker interface...

@rtack
Copy link

rtack commented Mar 20, 2015

http://central.sonatype.org/pages/ossrh-guide.html and http://central.sonatype.org/pages/apache-maven.html are guides on how to get things into maven central in general. This is already used for the maven-nar-plugin itself.

From
http://stackoverflow.com/questions/23160461/how-i-add-my-archtype-to-the-maven-central-archetype-catalog-xml it looks as if the packaging type needs to be set to "maven-archetype"
See also http://maven.apache.org/archetype/maven-archetype-plugin/

I might give it a try if nobody beats me to it.

@ctrueden
Copy link
Contributor

The nar-maven-plugin already has configuration in its POM to deploy to OSS Sonatype. We use this script to do it.

The other three repositories (maven-archetype-nar-exec, maven-archetype-nar-jni and maven-archetype-nar-lib) would need similar configuration. We should probably take the opportunity to create a shared pom-maven-nar parent from which all four projects inherit common configuration. Much (but by no means all) of the current nar-maven-plugin POM's configuration would be extracted there. Such a structure would make it very easy to deploy all four projects to OSS Sonatype in the same way.

Note that as things stand, those three archetype repositories have no updates to reflect the new project structure of NAR, etc. They were purely migrated from the old code. So e.g. the groupId is probably wrong. But I don't know much about how archetypes work, so I might be wrong too... 😉

@rtack
Copy link

rtack commented Mar 20, 2015

I've started working on this, copying over lots of the pom entry from the nar maven plugin. Also thought about using a parent for the archetypes. Will do so now after you encouragement.

@ctrueden
Copy link
Contributor

Awesome, keep us posted on progress, and any questions!

@ctrueden ctrueden modified the milestone: unscheduled Aug 6, 2015
@ctrueden ctrueden removed the dormant label Aug 6, 2015
@sewe
Copy link

sewe commented Sep 30, 2016

In addition to having the archetypes in the Central Repository, it would be nice if the Archetypes documentation page would contain copy-and-pastable mvn archetype:generate commands.

@ctrueden
Copy link
Contributor

ctrueden commented Sep 30, 2016

I guess @rtack did not have time to finish this? Anyone else want to take up the mantle and try to finish it?

@sewe As for the documentation page, good idea—please file a PR for that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants