Skip to content

Commit

Permalink
generate 2023.09 bom
Browse files Browse the repository at this point in the history
  • Loading branch information
amergey committed Sep 23, 2023
1 parent 960c113 commit beefc62
Show file tree
Hide file tree
Showing 13 changed files with 24,770 additions and 5 deletions.
4,341 changes: 4,341 additions & 0 deletions data/2023.09/bnd-output.txt

Large diffs are not rendered by default.

2,522 changes: 2,522 additions & 0 deletions data/2023.09/maven-artifacts.json

Large diffs are not rendered by default.

14,777 changes: 14,777 additions & 0 deletions data/2023.09/potential-maven-artifacts.json

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions data/2023.09/repolist.bndrun
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
-standalone true
-plugin.p2 \
aQute.bnd.repository.p2.provider.P2Repository; \
url="https://download.eclipse.org/releases/2023-09"
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ asciidoctorjVersion=2.2.0

assertjVersion=3.23.1
jsonUnitVersion=2.36.0
bndVersion=5.3.0
junitVersion=5.7.1
bndVersion=6.4.0
junitVersion=5.10.0
gsonVersion=2.8.7
mvnUtils=1.0.0

Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
88bf8b46e6210e5adcec69e34553b8f9
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
49b577273fd1829f5e5de4198011c334ad9da468
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
bb0c53b034ed2348755e431ee64e2ef1b6aa6507e07febb236836138763d3299
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
287649b448f6c9d1afc8349ed337fc0064abbcc62f6dbc3d5f9ef1fdd0223f380fcc57a33ade068e641aa16bcc0c43e4ecba4030de273f6816898eaade35477a
5 changes: 4 additions & 1 deletion src/main/resources/mavenMappings.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,15 @@
<mavenMappings namePattern="(org\.eclipse)(.*)$" groupId="$1.platform" artifactId="$1$2"/>
<mavenMappings namePattern="com\.ibm\.icu" groupId="com.ibm.icu" artifactId="icu4j" versionPattern="([^.]+)\.([^.]+)\.0(?:\..*)?" versionTemplate="$1.$2"/>
<mavenMappings namePattern="(com\.jcraft)\.(.*)" groupId="$1" artifactId="$2"/>
<mavenMappings namePattern="(com\.fasterxml\.jackson\.[^.]+)\.(.*)" groupId="$1" artifactId="$2"/>
<mavenMappings namePattern="com\.sun\.el\.javax\.el" groupId="com.sun.el" artifactId="el-ri" versionPattern="(.*)" versionTemplate="$1" />
<mavenMappings namePattern="com\.sun\.el" groupId="org.eclipse.jetty.orbit" artifactId="com.sun.el" versionPattern="(.*)" versionTemplate="$1" />
<mavenMappings namePattern="javassist" groupId="org.javassist" artifactId="javassist" versionPattern="([^.]+)\.([^.]+)\.([^.]+)\.([^.]+)" versionTemplate="$1.$2.$3-$4"/>
<mavenMappings namePattern="javax\.annotation" groupId="jakarta.annotation" artifactId="jakarta.annotation-api"/>
<mavenMappings namePattern="javax\.activation" groupId="com.sun.activation" artifactId="jakarta.activation" versionPattern="([^.]+)\.([^.]+)\.([^.]+)\.([^.]+)" versionTemplate="$1.$2.$3"/>
<mavenMappings namePattern="javax\.el" groupId="javax.el" artifactId="el-api" versionPattern="([^.]+)\.([^.]+)\.0(?:\..*)?" versionTemplate="$1.$2"/>
<mavenMappings namePattern="org\.jdom" groupId="org.jdom" artifactId="jdom" versionPattern="([^.]+)\.([^.]+)\.([^.]+)\.([^.]+)" versionTemplate="$1.$2.$3"/>
<mavenMappings namePattern="jakarta\.ws\.rs-api" groupId="jakarta.ws.rs" artifactId="jakarta.ws.rs-api" versionPattern="([^.]+)\.([^.]+)\.([^.]+)" versionTemplate="$1.$2.$3"/>
<mavenMappings namePattern="javax\.ws\.rs" groupId="jakarta.ws.rs" artifactId="jakarta.ws.rs-api" versionPattern="([^.]+)\.([^.]+)\.([^.]+)\.([^.]+)" versionTemplate="$1.$2.$3"/>
<mavenMappings namePattern="javax\.el-api" groupId="jakarta.el" artifactId="jakarta.el-api" versionPattern="(.*)" versionTemplate="$1"/>
<mavenMappings namePattern="jakarta\.xml\.bind" groupId="jakarta.xml.bind" artifactId="jakarta.xml.bind-api"/>
Expand Down Expand Up @@ -63,7 +66,7 @@
<mavenMappings namePattern="org\.apache\.batik\.([^.]+)$" groupId="org.apache.xmlgraphics" artifactId="batik-$1" versionPattern="([^.]+)\.([^.]+)\.0(?:\..*)?" versionTemplate="$1.$2"/>
<mavenMappings namePattern="org\.apache\.xmlgraphics$" groupId="org.apache.xmlgraphics" artifactId="xmlgraphics-commons" versionPattern="([^.]+)\.([^.]+)\.0(?:\..*)?" versionTemplate="$1.$2"/>
<mavenMappings namePattern="com.google.gson" groupId="com.google.code.gson" artifactId="gson"/>
<mavenMappings namePattern="com\.google\.guava$" groupId="com.google.guava" artifactId="guava" versionPattern="([^.]+)\.([^.]+)\.0(?:\..*)?" versionTemplate="$1.$2-jre"/>
<mavenMappings namePattern="com\.google\.guava$" groupId="com.google.guava" artifactId="guava" versionPattern="([^.]+)\.([^.]+)\.([^.]+)\.([^.]+)?" versionTemplate="$1.$2.$3-jre"/>
<mavenMappings namePattern="(com\.google\.guava)\.(.*)" groupId="$1" artifactId="$2"/>
<mavenMappings namePattern="com.sun.jna.platform" groupId="net.java.dev.jna" artifactId="jna-platform"/>
<mavenMappings namePattern="com.sun.jna" groupId="net.java.dev.jna" artifactId="jna"/>
Expand Down
48 changes: 46 additions & 2 deletions src/test/java/fr/jmini/utils/ecentral/ECentralTaskTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,50 @@ void testToMavenArtifactJavax() throws Exception {
assertThat(icu.getVersion())
.as("version")
.isEqualTo("3.0.0");

icu = ECentralTask.toMavenArtifact(new BndEntry("jakarta.ws.rs-api", "2.1.6"), mavenMappings)
.orElseThrow();
assertThat(icu.getGroupId())
.as("groupId")
.isEqualTo("jakarta.ws.rs");
assertThat(icu.getArtifactId())
.as("artifactId")
.isEqualTo("jakarta.ws.rs-api");
assertThat(icu.getVersion())
.as("version")
.isEqualTo("2.1.6");
}

@Test
void testToMavenArtifactJackson() throws Exception {
List<MavenMapping> mavenMappings = ECentralTask.readMavenMappings();
MavenArtifact icu = ECentralTask.toMavenArtifact(new BndEntry("com.fasterxml.jackson.core.jackson-annotations", "2.15.2"), mavenMappings)
.orElseThrow();
assertThat(icu.getGroupId())
.as("groupId")
.isEqualTo("com.fasterxml.jackson.core");
assertThat(icu.getArtifactId())
.as("artifactId")
.isEqualTo("jackson-annotations");
assertThat(icu.getVersion())
.as("version")
.isEqualTo("2.15.2");
}

@Test
void testToMavenArtifactJdom() throws Exception {
List<MavenMapping> mavenMappings = ECentralTask.readMavenMappings();
MavenArtifact icu = ECentralTask.toMavenArtifact(new BndEntry("org.jdom", "1.1.3.v20230812-160"), mavenMappings)
.orElseThrow();
assertThat(icu.getGroupId())
.as("groupId")
.isEqualTo("org.jdom");
assertThat(icu.getArtifactId())
.as("artifactId")
.isEqualTo("jdom");
assertThat(icu.getVersion())
.as("version")
.isEqualTo("1.1.3");
}

@Test
Expand Down Expand Up @@ -477,7 +521,7 @@ void testToMavenArtifactApacheCommons() throws Exception {
@Test
void testToMavenArtifactGuava() throws Exception {
List<MavenMapping> mavenMappings = ECentralTask.readMavenMappings();
MavenArtifact guava = ECentralTask.toMavenArtifact(new BndEntry("com.google.guava", "31.1.0.jre"), mavenMappings)
MavenArtifact guava = ECentralTask.toMavenArtifact(new BndEntry("com.google.guava", "32.1.2.jre"), mavenMappings)
.orElseThrow();
assertThat(guava.getGroupId())
.as("groupId")
Expand All @@ -487,7 +531,7 @@ void testToMavenArtifactGuava() throws Exception {
.isEqualTo("guava");
assertThat(guava.getVersion())
.as("version")
.isEqualTo("31.1-jre");
.isEqualTo("32.1.2-jre");

guava = ECentralTask.toMavenArtifact(new BndEntry("com.google.guava.failureaccess", "1.0.1"), mavenMappings)
.orElseThrow();
Expand Down
13 changes: 13 additions & 0 deletions src/test/java/fr/jmini/utils/ecentral/RunTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,19 @@
*/
class RunTest {

@Test
void run_2023_09() throws Exception {
Input input = new Input()
.withReleaseName("2023-09")
.withArtifactId("eclipse-full-dependencies");
ECentralTask task = new ECentralTask(input);
task.run();
String mavenArtifacts = Files.readString(task.getMavenArtifactsFile(), StandardCharsets.UTF_8);
String potentialMavenArtifacts = Files.readString(task.getPotentialMavenArtifactsFile(), StandardCharsets.UTF_8);

assertThatJson(mavenArtifacts).isEqualTo(potentialMavenArtifacts);
}

@Test
void run_2023_06() throws Exception {
Input input = new Input()
Expand Down

0 comments on commit beefc62

Please sign in to comment.