Gradle文件转换为Maven。

huangapple go评论92阅读模式
英文:

Gradle file to Maven

问题

以下是要翻译的内容:

我想将这个依赖项添加到我的Maven Spring应用程序中。

  1. repositories {
  2. maven {
  3. url = uri("https://maven.regulaforensics.com/RegulaDocumentReaderWebClient")
  4. }
  5. }
  6. dependencies {
  7. implementation("com.regula.documentreader:webclient:5.+")
  8. }

我有这段代码,它是一个Gradle文件,我想将这个依赖项添加到我的Spring应用程序中。

英文:

I want to add this dependency to my maven spring application.

  1. repositories {
  2. maven {
  3. url = uri("https://maven.regulaforensics.com/RegulaDocumentReaderWebClient")
  4. }
  5. }
  6. dependencies {
  7. implementation("com.regula.documentreader:webclient:5.+")
  8. }

I am having this code which is of a gradle file and I want to add this dependency to my Spring application.

答案1

得分: 0

在你的应用程序的pom.xml文件中,你需要添加一个仓库标签,然后是一个依赖标签,像这样:

  1. <repositories>
  2. <repository>
  3. <id>regulaforensics</id>
  4. <url>https://maven.regulaforensics.com/RegulaDocumentReaderWebClient</url>
  5. </repository>
  6. </repositories>
  7. 然后
  8. <dependencies>
  9. <dependency>
  10. <groupId>com.regula.documentreader</groupId>
  11. <artifactId>webclient</artifactId>
  12. <version>5.8.4</version>
  13. </dependency>
  14. </dependencies>
英文:

In your application pom.xml, you add a repository tag then, a dependency tag, like this:

  1. &lt;repositories&gt;
  2. &lt;repository&gt;
  3. &lt;id&gt;regulaforensics&lt;/id&gt;
  4. &lt;url&gt;https://maven.regulaforensics.com/RegulaDocumentReaderWebClient&lt;/url&gt;
  5. &lt;/repository&gt;
  6. &lt;/repositories&gt;

then

  1. &lt;dependencies&gt;
  2. &lt;dependency&gt;
  3. &lt;groupId&gt;com.regula.documentreader&lt;/groupId&gt;
  4. &lt;artifactId&gt;webclient&lt;/artifactId&gt;
  5. &lt;version&gt;5.8.4&lt;/version&gt;
  6. &lt;/dependency&gt;
  7. &lt;/dependencies&gt;

huangapple
  • 本文由 发表于 2023年5月18日 12:58:24
  • 转载请务必保留本文链接:https://go.coder-hub.com/76277850.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定