X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=runtime%2Forg.argeo.slc.repo%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Frepo%2Fmaven%2FMigration_01_03.java;h=baf6ec723e0f852b4370e79c5921552de3391533;hb=e70fb767d8ff5972d88ab436762e71ea622a0f72;hp=325d352b0fecf2557f7cc399b150f6f33c43c911;hpb=6100175ea489062df9ad9a47fb5bbbb904595b2f;p=gpl%2Fargeo-slc.git diff --git a/runtime/org.argeo.slc.repo/src/main/java/org/argeo/slc/repo/maven/Migration_01_03.java b/runtime/org.argeo.slc.repo/src/main/java/org/argeo/slc/repo/maven/Migration_01_03.java index 325d352b0..baf6ec723 100644 --- a/runtime/org.argeo.slc.repo/src/main/java/org/argeo/slc/repo/maven/Migration_01_03.java +++ b/runtime/org.argeo.slc.repo/src/main/java/org/argeo/slc/repo/maven/Migration_01_03.java @@ -1,8 +1,22 @@ +/* + * Copyright (C) 2007-2012 Argeo GmbH + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.argeo.slc.repo.maven; import java.io.IOException; import java.util.ArrayList; -import java.util.Arrays; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -55,7 +69,6 @@ public class Migration_01_03 implements Runnable, SlcNames { private Repository repository; private String sourceWorkspace; private String targetWorkspace; - private String osgiProfile = "JavaSE-1.6.profile"; private List excludedBundles = new ArrayList(); private Map symbolicNamesMapping = new HashMap(); @@ -126,14 +139,22 @@ public class Migration_01_03 implements Runnable, SlcNames { Artifact origArtifact = RepoUtils.asArtifact(origArtifactNode); // skip eclipse artifacts - if ((origArtifact.getGroupId().startsWith("org.eclipse") && !origArtifact - .getArtifactId().equals("org.eclipse.osgi")) - || (origArtifact.getArtifactId().startsWith("org.polymap"))) { + if ((origArtifact.getGroupId().startsWith("org.eclipse") && !(origArtifact + .getArtifactId().equals("org.eclipse.osgi") + || origArtifact.getArtifactId().equals( + "org.eclipse.osgi.source") || origArtifact + .getArtifactId().startsWith("org.eclipse.rwt.widgets.upload"))) + || origArtifact.getArtifactId().startsWith("com.ibm.icu")) { if (log.isDebugEnabled()) log.debug("Skip " + origArtifact); return; } + // skip SpringSource ActiveMQ + if (origArtifact.getArtifactId().startsWith( + "com.springsource.org.apache.activemq")) + return; + String origJarNodeName = MavenConventionsUtils .artifactFileName(origArtifact); if (!origArtifactNode.hasNode(origJarNodeName)) @@ -260,9 +281,16 @@ public class Migration_01_03 implements Runnable, SlcNames { // target coordinates final String targetGroupId; - if (origArtifact.getGroupId().startsWith("org.eclipse") + if (origArtifact.getArtifactId().startsWith( + "org.eclipse.rwt.widgets.upload")) + targetGroupId = "org.argeo.tp.rap"; + else if (origArtifact.getArtifactId().startsWith("org.polymap")) + targetGroupId = "org.argeo.tp.rap"; + else if (origArtifact.getGroupId().startsWith("org.eclipse") && !origArtifact.getArtifactId().equals("org.eclipse.osgi")) - targetGroupId = "org.argeo.tp.eclipse"; + throw new SlcException(origArtifact + " should have been excluded");// targetGroupId + // = + // "org.argeo.tp.eclipse"; else targetGroupId = "org.argeo.tp";