|
142 | 142 | </dependency> |
143 | 143 | </dependencies> |
144 | 144 |
|
145 | | - <build> |
146 | | - <plugins> |
147 | | - <plugin> |
148 | | - <artifactId>maven-clean-plugin</artifactId> |
149 | | - <configuration> |
150 | | - <filesets> |
151 | | - <fileset> |
152 | | - <directory>${project.basedir}/src/main/java/com/sap/ai/sdk/core/client</directory> |
153 | | - <includes> |
154 | | - <include>**/*</include> |
155 | | - </includes> |
156 | | - </fileset> |
157 | | - </filesets> |
158 | | - </configuration> |
159 | | - <executions> |
160 | | - <execution> |
161 | | - <id>delete-aicore-generated-client</id> |
162 | | - </execution> |
163 | | - </executions> |
164 | | - </plugin> |
165 | | - <plugin> |
166 | | - <groupId>com.sap.cloud.sdk.datamodel</groupId> |
167 | | - <artifactId>openapi-generator-maven-plugin</artifactId> |
168 | | - <configuration> |
169 | | - <outputDirectory>${project.basedir}/src/main/java</outputDirectory> |
170 | | - <apiMaturity>released</apiMaturity> |
171 | | - <enableOneOfAnyOfGeneration>true</enableOneOfAnyOfGeneration> |
172 | | - <compileScope>COMPILE</compileScope> |
173 | | - <!-- Do not delete the output directory because it contains non-generated code --> |
174 | | - <!-- The generated client is instead deleted by the maven-clean-plugin here above --> |
175 | | - <deleteOutputDirectory>false</deleteOutputDirectory> |
176 | | - </configuration> |
177 | | - <executions> |
178 | | - <execution> |
179 | | - <id>aicore</id> |
180 | | - <goals> |
181 | | - <goal>generate</goal> |
182 | | - </goals> |
183 | | - <phase>generate-sources</phase> |
| 145 | + <profiles> |
| 146 | + <profile> |
| 147 | + <id>generate</id> |
| 148 | + <activation> |
| 149 | + <activeByDefault>false</activeByDefault> |
| 150 | + <property> |
| 151 | + <name>generate</name> |
| 152 | + </property> |
| 153 | + </activation> |
| 154 | + <build> |
| 155 | + <plugins> |
| 156 | + <plugin> |
| 157 | + <groupId>com.sap.cloud.sdk.datamodel</groupId> |
| 158 | + <artifactId>openapi-generator-maven-plugin</artifactId> |
184 | 159 | <configuration> |
185 | | - <inputSpec>${project.basedir}/src/main/resources/spec/aicore.yaml</inputSpec> |
186 | | - <apiPackage>com.sap.ai.sdk.core.client</apiPackage> |
187 | | - <modelPackage>com.sap.ai.sdk.core.client.model</modelPackage> |
188 | | - <additionalProperties> |
189 | | - <pojoBuilderMethodName>create</pojoBuilderMethodName> |
190 | | - <pojoBuildMethodName/> |
191 | | - <pojoConstructorVisibility>protected</pojoConstructorVisibility> |
192 | | - <enumUnknownDefaultCase>true</enumUnknownDefaultCase> |
193 | | - <removeOperationIdPrefix>true</removeOperationIdPrefix> |
194 | | - <removeOperationIdPrefixDelimiter>\.</removeOperationIdPrefixDelimiter> |
195 | | - <removeOperationIdPrefixCount>3</removeOperationIdPrefixCount> |
196 | | - </additionalProperties> |
| 160 | + <outputDirectory>${project.basedir}/src/main/java</outputDirectory> |
| 161 | + <apiMaturity>released</apiMaturity> |
| 162 | + <enableOneOfAnyOfGeneration>true</enableOneOfAnyOfGeneration> |
| 163 | + <compileScope>COMPILE</compileScope> |
| 164 | + <deleteOutputDirectory>true</deleteOutputDirectory> |
197 | 165 | </configuration> |
198 | | - </execution> |
199 | | - </executions> |
200 | | - </plugin> |
201 | | - </plugins> |
202 | | - </build> |
| 166 | + <executions> |
| 167 | + <execution> |
| 168 | + <id>aicore</id> |
| 169 | + <goals> |
| 170 | + <goal>generate</goal> |
| 171 | + </goals> |
| 172 | + <phase>generate-sources</phase> |
| 173 | + <configuration> |
| 174 | + <inputSpec>${project.basedir}/src/main/resources/spec/aicore.yaml</inputSpec> |
| 175 | + <apiPackage>com.sap.ai.sdk.core.client</apiPackage> |
| 176 | + <modelPackage>com.sap.ai.sdk.core.client.model</modelPackage> |
| 177 | + <additionalProperties> |
| 178 | + <pojoBuilderMethodName>create</pojoBuilderMethodName> |
| 179 | + <pojoBuildMethodName/> |
| 180 | + <pojoConstructorVisibility>protected</pojoConstructorVisibility> |
| 181 | + <enumUnknownDefaultCase>true</enumUnknownDefaultCase> |
| 182 | + <removeOperationIdPrefix>true</removeOperationIdPrefix> |
| 183 | + <removeOperationIdPrefixDelimiter>\.</removeOperationIdPrefixDelimiter> |
| 184 | + <removeOperationIdPrefixCount>3</removeOperationIdPrefixCount> |
| 185 | + </additionalProperties> |
| 186 | + </configuration> |
| 187 | + </execution> |
| 188 | + </executions> |
| 189 | + </plugin> |
| 190 | + </plugins> |
| 191 | + </build> |
| 192 | + </profile> |
| 193 | + </profiles> |
203 | 194 | </project> |
0 commit comments