Skip to content

Commit 01a7b20

Browse files
committed
Rename the main module and all-in-one JAR
The main module is now named "rhino", and exports the "org.mozilla.rhino" package. The "rhino-all" module builds the "rhino-all.jar", which contains all the modules except the ScriptEngine (like the old "rhino.jar") and is sufficient to run Rhino using "java -jar".
1 parent 39aad21 commit 01a7b20

File tree

402 files changed

+48
-45
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

402 files changed

+48
-45
lines changed

README.md

Lines changed: 3 additions & 3 deletions

benchmarks/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44
}
55

66
dependencies {
7-
implementation project(':rhino-runtime')
7+
implementation project(':rhino')
88
implementation project(':rhino-tools')
99
}
1010

examples/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
}
44

55
dependencies {
6-
implementation project(':rhino-runtime')
6+
implementation project(':rhino')
77
implementation project(':rhino-tools')
88
implementation project(':rhino-xml')
99
}

gradle.properties

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,4 @@ version=1.7.16-SNAPSHOT
44
mavenSnapshotRepo=https://oss.sonatype.org/content/repositories/snapshots
55
mavenReleaseRepo=https://oss.sonatype.org/service/local/staging/deploy/maven2/
66
org.gradle.caching=true
7-
org.gradle.configuration-cache=true
8-
org.gradle.configuration-cache.problems=warn
97
org.gradle.parallel=true

rhino-runtime/build.gradle renamed to rhino-all/build.gradle

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,39 @@
11
plugins {
22
id 'rhino.library-conventions'
3+
id 'com.github.johnrengelman.shadow' version '8.1.1'
4+
id 'application'
35
}
46

7+
application {
8+
mainClass = 'org.mozilla.javascript.tools.shell.Main'
9+
}
10+
11+
run {
12+
standardInput = System.in
13+
}
14+
15+
dependencies {
16+
implementation project(':rhino')
17+
implementation project(':rhino-tools')
18+
implementation project(':rhino-xml')
19+
}
20+
21+
shadowJar {
22+
// Ensure that the "jar" from this step is the shadowed one that we want to
23+
// publish in Maven.
24+
archiveClassifier.set('')
25+
manifest {
26+
inheritFrom(project.tasks.jar.manifest)
27+
}
28+
}
529

630
publishing {
731
publications {
8-
rhinoruntime(MavenPublication) {
32+
rhinoall(MavenPublication) {
933
from components.java
10-
artifacts = [jar, sourceJar, javadocJar]
34+
artifacts = [jar]
1135
pom {
12-
description = "Rhino JavaScript runtime jar, excludes XML, tools ScriptEngine wrapper"
36+
description = "Rhino JavaScript all-in-one JAR, not for use with modular Java projects"
1337
url = "https://mozilla.github.io/rhino/"
1438
licenses {
1539
license {

rhino-engine/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
}
44

55
dependencies {
6-
implementation project(':rhino-runtime')
6+
implementation project(':rhino')
77
}
88

99
publishing {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module org.mozilla.rhino.engine {
22
exports org.mozilla.javascript.engine;
33

4-
requires org.mozilla.rhino.runtime;
4+
requires org.mozilla.rhino;
55
requires java.scripting;
66
}

rhino-tools/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
}
44

55
dependencies {
6-
implementation project(':rhino-runtime')
6+
implementation project(':rhino')
77
}
88

99
publishing {

rhino-tools/src/main/java/module-info.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
module org.mozilla.rhino.tools {
2-
requires org.mozilla.rhino.runtime;
2+
requires org.mozilla.rhino;
33
requires java.desktop;
44

55
exports org.mozilla.javascript.tools.debugger;

rhino-xml/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ plugins {
33
}
44

55
dependencies {
6-
implementation project(':rhino-runtime')
6+
implementation project(':rhino')
77
}
88

99
publishing {

0 commit comments

Comments
 (0)