Closed GoogleCodeExporter closed 9 years ago
i made some changes to the compiler plugin. now relative paths are evaluated
based on a base folder. default for this is new File("."). For properties files
the base folder is the directory the properties file is in.
sorry for the rather lengthy patch. my code formatter was active.
Original comment by baetz.al...@googlemail.com
on 18 Jul 2012 at 9:24
Attachments:
It would be easier for me to apply your changes when your patch only includes
the relevant stuff. (too much formatting garbage)
Original comment by david.yu...@gmail.com
on 19 Jul 2012 at 5:01
[deleted comment]
[deleted comment]
new patch
Original comment by baetz.al...@googlemail.com
on 20 Jul 2012 at 8:57
Attachments:
Thanks for the patch (sorry for late response).
I added a few minor modifications for flexibility.
So in a submodule, the heirarchy would be something like this.
foo
foo-baz
pom.xml
baz.properties
src
target
The contents of baz.properties:
#begin
modules = baz
baz.output = java_bean
baz.outputDir = target/generated-sources
baz.source = src/main/proto
baz.options = separate_schema
#end
With that layout, the config on pom.xml would be as simple as:
<plugin>
<groupId>com.dyuproject.protostuff</groupId>
<artifactId>protostuff-maven-plugin</artifactId>
<version>${protostuff-version}</version>
<configuration>
<modulesFile>baz.properties</modulesFile>
</configuration>
<executions>
<execution>
<id>generate-sources</id>
<phase>generate-sources</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
</plugin>
If you want to import other modules protos, you might want put the protos in
src/main/resources so it can be looked up from classpath (add the module as a
maven dependency)
Added @ rev 1552
Original comment by david.yu...@gmail.com
on 29 Aug 2012 at 10:04
Original issue reported on code.google.com by
baetz.al...@googlemail.com
on 11 Jul 2012 at 1:55