swagger-api / swagger-codegen

swagger-codegen contains a template-driven engine to generate documentation, API clients and server stubs in different languages by parsing your OpenAPI / Swagger definition.
http://swagger.io
Apache License 2.0
16.79k stars 6.02k forks source link

Create codegen template from Maven command #818

Closed alblue closed 9 years ago

alblue commented 9 years ago

All of the examples in the wiki page require the code to be built first, then executed. Why not publish them as a canonical build into Maven central and then use that instead?

Someone already has published these into Maven central, but under different groupids:

http://search.maven.org/#search%7Cga%7C1%7Cswagger-codegen

What I'd like to be able to do is run something like:

mvn io.swagger:swagger-codegen:2.1.0:generate-java -Dpackage=com.example -Droot=/blah ...

webron commented 9 years ago

Umm, those are our builds in central... and that is the groupid we currently use :) We haven't moved toe projects to io.swagger yet, though that would happen soon.

fehguy commented 9 years ago

We actually do publish an executable jar:

https://oss.sonatype.org/content/repositories/snapshots/com/wordnik/swagger-codegen-cli/