将 wsdl 文件安装到 Maven 存储库中

发布于 2024-10-14 12:18:35 字数 270 浏览 14 评论 0原文

我正在尝试将 wsdl 文件安装到远程 Maven 存储库中,以便我可以按照 这篇博文

我确信它可以手动完成,但我想要一个实际的 Maven 项目,这样我就可以利用发布插件进行标记等。

有人有这方面的经验吗?

I'm trying to install a wsdl file into a remote Maven repository so I can reference it in a CXF project as per this blog post.

I'm sure it could be done manually, but I want an actual maven project so I can make use of the release plugin for tagging etc.

Has anybody got experience with this?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

向地狱狂奔 2024-10-21 12:18:35

您可以使用构建助手maven插件来做这个。这是一个指示性代码片段

 <build>
 ...
     <plugins>
     ...
         <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>build-helper-maven-plugin</artifactId>
            <executions>
                <execution>
                    <id>attach-artifacts</id>
                    <phase>package</phase>
                    <goals>
                        <goal>attach-artifact</goal>
                    </goals>
                    <configuration>
                        <artifacts>
                            <artifact>
                                <file>${wsdlLocation}/project.wsdl</file>
                                <type>wsdl</type>
                            </artifact>
                        </artifacts>
                   </configuration>
               </execution>
            </executions>
        </plugin>
    </plugins>
</build.

You can use the build helper maven plugin to do this. Here is an indicative code snippet

 <build>
 ...
     <plugins>
     ...
         <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>build-helper-maven-plugin</artifactId>
            <executions>
                <execution>
                    <id>attach-artifacts</id>
                    <phase>package</phase>
                    <goals>
                        <goal>attach-artifact</goal>
                    </goals>
                    <configuration>
                        <artifacts>
                            <artifact>
                                <file>${wsdlLocation}/project.wsdl</file>
                                <type>wsdl</type>
                            </artifact>
                        </artifacts>
                   </configuration>
               </execution>
            </executions>
        </plugin>
    </plugins>
</build.
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文