maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hbout...@apache.org
Subject [11/48] maven-resolver git commit: Accounted for refactoring of AuthenticationBuilder and RemoteRepository in aether-api
Date Fri, 26 May 2017 21:15:47 GMT
Accounted for refactoring of AuthenticationBuilder and RemoteRepository in aether-api


Project: http://git-wip-us.apache.org/repos/asf/maven-resolver/repo
Commit: http://git-wip-us.apache.org/repos/asf/maven-resolver/commit/52f81d29
Tree: http://git-wip-us.apache.org/repos/asf/maven-resolver/tree/52f81d29
Diff: http://git-wip-us.apache.org/repos/asf/maven-resolver/diff/52f81d29

Branch: refs/heads/demos
Commit: 52f81d2904801458f9ce317f16f4f71d585838a8
Parents: 40100e3
Author: Benjamin Bentmann <bentmann@sonatype.com>
Authored: Sun Sep 30 17:24:21 2012 +0200
Committer: Benjamin Bentmann <bentmann@sonatype.com>
Committed: Sun Sep 30 17:28:08 2012 +0200

----------------------------------------------------------------------
 .../java/org/eclipse/aether/examples/DeployArtifacts.java    | 4 ++--
 .../main/java/org/eclipse/aether/examples/aether/Aether.java | 8 ++++----
 .../main/java/org/eclipse/aether/examples/util/Booter.java   | 2 +-
 3 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/maven-resolver/blob/52f81d29/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/DeployArtifacts.java
----------------------------------------------------------------------
diff --git a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/DeployArtifacts.java
b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/DeployArtifacts.java
index 5fdefd2..b8757bb 100644
--- a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/DeployArtifacts.java
+++ b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/DeployArtifacts.java
@@ -44,8 +44,8 @@ public class DeployArtifacts
         pomArtifact = pomArtifact.setFile( new File( "pom.xml" ) );
 
         RemoteRepository distRepo =
-            new RemoteRepository( "org.eclipse.aether.examples", "default",
-                                  new File( "target/dist-repo" ).toURI().toString() );
+            new RemoteRepository.Builder( "org.eclipse.aether.examples", "default",
+                                  new File( "target/dist-repo" ).toURI().toString() ).build();
 
         DeployRequest deployRequest = new DeployRequest();
         deployRequest.addArtifact( jarArtifact ).addArtifact( pomArtifact );

http://git-wip-us.apache.org/repos/asf/maven-resolver/blob/52f81d29/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/aether/Aether.java
----------------------------------------------------------------------
diff --git a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/aether/Aether.java
b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/aether/Aether.java
index c1f3f4f..6aee749 100644
--- a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/aether/Aether.java
+++ b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/aether/Aether.java
@@ -63,7 +63,7 @@ public class Aether
         RepositorySystemSession session = newSession();
         Dependency dependency =
             new Dependency( new DefaultArtifact( groupId, artifactId, "", "jar", version
), "runtime" );
-        RemoteRepository central = new RemoteRepository( "central", "default", remoteRepository
);
+        RemoteRepository central = new RemoteRepository.Builder( "central", "default", remoteRepository
).build();
 
         CollectRequest collectRequest = new CollectRequest();
         collectRequest.setRoot( dependency );
@@ -99,9 +99,9 @@ public class Aether
     {
         RepositorySystemSession session = newSession();
 
-        RemoteRepository nexus = new RemoteRepository( "nexus", "default", remoteRepository
);
-        Authentication authentication = new AuthenticationBuilder().username( "admin" ).password(
"admin123" ).build();
-        nexus.setAuthentication( authentication );
+        Authentication auth = new AuthenticationBuilder().addUsername( "admin" ).addPassword(
"admin123" ).build();
+        RemoteRepository nexus =
+            new RemoteRepository.Builder( "nexus", "default", remoteRepository ).setAuthentication(
auth ).build();
 
         DeployRequest deployRequest = new DeployRequest();
         deployRequest.addArtifact( artifact ).addArtifact( pom );

http://git-wip-us.apache.org/repos/asf/maven-resolver/blob/52f81d29/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/util/Booter.java
----------------------------------------------------------------------
diff --git a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/util/Booter.java
b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/util/Booter.java
index 412bfab..bd0171a 100644
--- a/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/util/Booter.java
+++ b/aether-demo-snippets/src/main/java/org/eclipse/aether/examples/util/Booter.java
@@ -46,7 +46,7 @@ public class Booter
 
     public static RemoteRepository newCentralRepository()
     {
-        return new RemoteRepository( "central", "default", "http://repo1.maven.org/maven2/"
);
+        return new RemoteRepository.Builder( "central", "default", "http://repo1.maven.org/maven2/"
).build();
     }
 
 }


Mime
View raw message