dtrott / maven-thrift-plugin

Maven Thrift Plugin that executes the thrift code generator (base on protocol buffers plugin)
120 stars 68 forks source link

Should not clean original files #24

Open tobegit3hub opened 10 years ago

tobegit3hub commented 10 years ago

If I specify outputDirectory as ./src/main/java/, it will cleanup all my source files in ./src/main/java.

I would like generate the thrift java files so that the same project could import and use it. But if I set the outputDirectory as the path of my source code, it will cleanup all files.

tobegit3hub commented 10 years ago

I'm reading AbstractThriftMojo.java and find that the line 183 is going to clean the complete directory to avoid the old generated file. I don't think it's reasonable way to fix this problem. May delete the specified file is enough or just print the hint to remind the user. Cleaning all files is really dangerous and the first time I set the current path in outputDirectory it cleanup my project.