Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Using the nexus-maven-bridge-plugin for maven effective pom "service".

  • Loading branch information...
commit e77671ebcb0c569f37a3e42d61402e5ccac00098 1 parent 2c91c88
Tamas Cservenak authored mkristian committed
2  nexus-ruby-plugin/pom.xml
@@ -67,7 +67,7 @@
67 67 <dependency>
68 68 <groupId>org.sonatype.nexus.plugins</groupId>
69 69 <artifactId>nexus-maven-bridge-plugin</artifactId>
70   - <version>${nexus-version}</version>
  70 + <version>1.0-SNAPSHOT</version>
71 71 <scope>provided</scope>
72 72 <type>nexus-plugin</type>
73 73 </dependency>
10 nexus-ruby-plugin/src/main/java/org/sonatype/nexus/plugins/ruby/DefaultRubyRepositoryHelper.java
@@ -2,6 +2,7 @@
2 2
3 3 import java.io.File;
4 4 import java.io.IOException;
  5 +import java.util.Arrays;
5 6
6 7 import org.apache.maven.index.artifact.Gav;
7 8 import org.apache.maven.model.Model;
@@ -9,8 +10,7 @@
9 10 import org.apache.maven.model.building.ModelBuildingException;
10 11 import org.codehaus.plexus.component.annotations.Component;
11 12 import org.codehaus.plexus.component.annotations.Requirement;
12   -import org.sonatype.nexus.plugins.maven.bridge.BuildModelRequest;
13   -import org.sonatype.nexus.plugins.maven.bridge.MavenBridge;
  13 +import org.sonatype.nexus.plugins.mavenbridge.NexusMavenBridge;
14 14 import org.sonatype.nexus.proxy.LocalStorageException;
15 15 import org.sonatype.nexus.proxy.ResourceStoreRequest;
16 16 import org.sonatype.nexus.proxy.item.StorageFileItem;
@@ -29,7 +29,7 @@
29 29 private MetadataLocator metadataLocator;
30 30
31 31 @Requirement
32   - private MavenBridge bridge;
  32 + private NexusMavenBridge bridge;
33 33
34 34 public MetadataLocator getMetadataLocator()
35 35 {
@@ -89,9 +89,7 @@ public MavenArtifact getMavenArtifactForItem( MavenRepository masterRepository,
89 89
90 90 try
91 91 {
92   - BuildModelRequest request = new BuildModelRequest( new FileModelSource( pomFile ), masterRepository );
93   -
94   - model = bridge.buildModel( request );
  92 + model = bridge.buildModel( new FileModelSource( pomFile ), Arrays.asList( masterRepository ) );
95 93 }
96 94 catch ( ModelBuildingException e )
97 95 {

0 comments on commit e77671e

Please sign in to comment.
Something went wrong with that request. Please try again.