Please look at the README. when you’re running your own custom generator, you need to specify the individual libraries.
https://github.com/swagger-api/swagger-codegen#making-your-own-codegen-modules <https://github.com/swagger-api/swagger-codegen#making-your-own-codegen-modules> There is an exact java command example in there that should help out. > On Jul 11, 2016, at 8:52 AM, [email protected] wrote: > > I found this question in stack overflow > http://stackoverflow.com/questions/33403791/swagger-codegen-custom-generator-classnotfound > > <http://stackoverflow.com/questions/33403791/swagger-codegen-custom-generator-classnotfound>and > I keep having the same problem. > I have no idea what it might be > > El viernes, 8 de julio de 2016, 13:35:23 (UTC-3), [email protected] escribió: > I´m trying to use my own model codegen outside of the Swagger Codegen project > (it works fine if I place the classes and templates inside the codegen > project). > > I have created the jar for my library following this steps > <https://github.com/swagger-api/swagger-codegen/tree/v2.1.6#making-your-own-codegen-modules> > and downloaded the swagger-codege-cli.jar from the maven repository. > > When I run this: > C:\Users\ls>java -cp swagger-codegen-cli-2.1.6.jar > io.swagger.codegen.SwaggerCodegen > > Available languages: [android, aspnet5, async-scala, csharp, dart, flash, > python-flask, go, java, jaxrs, jaxrs-cxf, jaxrs-resteasy, inflector, > javascript, javascript-closure-angular, jmeter, nodejs-server, objc, perl, > php, python, qt5cpp, ruby, scala, scalatra, silex-PHP, sinatra, slim, > spring-mvc, dynamic-html, html, swagger, swagger-yaml, swift, tizen, > typescript-angular, typescript-node, akka-scala, CsharpDotNet2, clojure, > haskell-servant] > > > > > It works just fine, but when I run this: > > C:\Users\ls>java -cp > output/Genexus/target/GenexusCodegen-swagger-codegen-1.0.0.jar:swagger-codegen-cli-2.1.6.jar > io.swagger.codegen.SwaggerCodegen generate -lgenexus -i > https://s3.amazonaws.com/genexuss3test/issueSwagger.yaml > <http://s3.amazonaws.com/genexuss3test/issueSwagger.yaml> > Error: Could not find or load main class io.swagger.codegen.SwaggerCodegen > > I keep getting that error, I have double check the errors and it seems to be > ok. > Here you can find the jar for my own codegen > https://drive.google.com/open?id=0B4p45mjTMTnLeElsMWN4VWdFOFU > <https://drive.google.com/open?id=0B4p45mjTMTnLeElsMWN4VWdFOFU> > Any help is welcome, thanks! > > -- > You received this message because you are subscribed to the Google Groups > "Swagger" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] > <mailto:[email protected]>. > For more options, visit https://groups.google.com/d/optout > <https://groups.google.com/d/optout>. -- You received this message because you are subscribed to the Google Groups "Swagger" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
