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

Add create, list-extensions and add-extension mojos #165

Merged
merged 7 commits into from
Dec 3, 2018

Conversation

cescoffier
Copy link
Member

Example of usage:

# Create a new project from scratch - prompt the user
mvn org.jboss.shamrock:shamrock-maven-plugin:1.0.0.Alpha1-SNAPSHOT:create
# Note if there is already a project, it extends the `pom.xml` file

# List extensions
mvn shamrock:list-extensions

# Add extensions to the project
mvn shamrock:add-extension -Dextensions="Eclipse Vert.x, JPA"

This PR is related to #157

Generate a test for the generated resources
Implementation of the list-extensions mojo
Implementation of the add-extension mojo

These Maven goals are related to #157
Copy link
Member

@stuartwdouglas stuartwdouglas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am ok with this as long as it is understood that this is just a short term thing for M1, that will be replaced later.

Thinking about it I am not actually sure the main repo is the place for this. Would there be any real downside to having these CLI style mojo's under a different plugin artifact?

<dependency>
<groupId>jline</groupId>
<artifactId>jline</artifactId>
<version>2.14.6</version>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There should probably be managed in the parent pom

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, will fix it.

@cescoffier
Copy link
Member Author

If we move it outside of the main plugin, it needs another "prefix" and cannot reuse "shamrock" (or whatever it will be).

So this would not be possible:

mvn shamrock:list-extensions

It would be something like:

mvn shamrock-cli:list-extensions
mvn shamrock:dev

Copy link
Member

@stuartwdouglas stuartwdouglas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From a usability perspective then I guess it is better to just have them all in the same module then.

@@ -0,0 +1,185 @@
[
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't really our long-term solution though, right? Wouldn't we want to maintain a published extension list of some sort?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Definitely a placeholder for something better later. These commands are just there until we get a proper CLI.

For the extension, we will need a repository/registry somewhere. I've attempted to scan maven central, but it's not a good way (required > 24 hours to scan the artifacts...). I think this registry will be part of the web site.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We definitely need a real discovery mechanism. I am happy to merge this as it makes it easy for people to get started when we do the internal reveal, however I this we need to make sure that everyone understands that this is a temporary solution.

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

Successfully merging this pull request may close these issues.

3 participants