Skip to content

Commit

Permalink
#445: shade
Browse files Browse the repository at this point in the history
  • Loading branch information
yegor256 committed Dec 23, 2024
1 parent 2023ae4 commit d5a9cbb
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ target/
.mvn/
temp/
*.tgz
eodocs.html
mvnw/dependency-reduced-pom.xml
9 changes: 9 additions & 0 deletions mvnw/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ SOFTWARE.
<groupId>org.eolang</groupId>
<artifactId>eoc</artifactId>
<version>0.0.0</version>
<packaging>jar</packaging>
<properties>
<jeo.version>0.6.26</jeo.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand All @@ -43,11 +44,13 @@ SOFTWARE.
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>5.11.4</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-engine</artifactId>
<version>5.11.4</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
Expand Down Expand Up @@ -80,6 +83,7 @@ SOFTWARE.
<artifactId>eo-maven-plugin</artifactId>
<version>${eo.version}</version>
<configuration>
<withRuntimeDependency>false</withRuntimeDependency>
<excludeSources>**/.eoc/**</excludeSources>
<sodgIncludes>${eo.sodgIncludes}</sodgIncludes>
<sodgExcludes>${eo.sodgExcludes}</sodgExcludes>
Expand Down Expand Up @@ -110,11 +114,16 @@ SOFTWARE.
<configuration>
<archive>
<manifest>
<addClasspath>true</addClasspath>
<mainClass>org.eolang.Main</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<version>3.6.0</version>
</plugin>
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.5.2</version>
Expand Down
2 changes: 1 addition & 1 deletion src/commands/java/link.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const path = require('path');
*/
module.exports = function(opts) {
const jar = path.resolve(opts.target, 'eoc.jar');
return mvnw(['jar:jar'].concat(flags(opts)), opts.target, opts.batch).then((r) => {
return mvnw(['jar:jar', 'shade:shade'].concat(flags(opts)), opts.target, opts.batch).then((r) => {
console.info('Executable JAR created at %s', rel(jar));
return r;
});
Expand Down
1 change: 0 additions & 1 deletion test/commands/test_link.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ describe('link', function() {
'target/generated-sources/EOfoo/EObar/EOlink.java',
'target/generated-sources/EOorg/EOeolang/EObytes.java',
'target/classes/EOfoo/EObar/EOlink.class',
'target/classes/org/eolang/Phi.class',
'target/classes/EOorg/EOeolang/EOnumber.class',
'target/eoc.jar',
]
Expand Down

0 comments on commit d5a9cbb

Please sign in to comment.