Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
GZYangKui committed Jan 29, 2023
1 parent 5ed20e0 commit faf159b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 42 deletions.
37 changes: 1 addition & 36 deletions app/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
<javafx.version>19</javafx.version>
</properties>

<version>1.0.0.RELEASE</version>
<artifactId>app</artifactId>

<dependencies>
Expand Down Expand Up @@ -68,42 +69,6 @@
</compilerArgs>
</configuration>
</plugin>
<!-- <plugin>-->
<!-- <groupId>org.apache.maven.plugins</groupId>-->
<!-- <artifactId>maven-shade-plugin</artifactId>-->
<!-- <version>3.4.1</version>-->
<!-- <executions>-->
<!-- <execution>-->
<!-- <goals>-->
<!-- <goal>shade</goal>-->
<!-- </goals>-->
<!-- <configuration>-->
<!-- <overwriteExistingFiles>true</overwriteExistingFiles>-->
<!-- <module>-->
<!-- <moduleInfoFile>-->
<!-- src/main/java/module-info.java-->
<!-- </moduleInfoFile>-->
<!-- </module>-->
<!-- <transformers>-->
<!-- <transformer-->
<!-- implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">-->
<!-- <manifestEntries>-->
<!-- <Main-class>cn.navclub.nes4j.app.Launcher</Main-class>-->
<!-- </manifestEntries>-->
<!-- </transformer>-->
<!-- </transformers>-->
<!-- <artifactSet>-->
<!-- <excludes>-->
<!-- <exclude>javafx:*</exclude>-->
<!-- <exclude>org.*</exclude>-->
<!-- <exclude>com.*</exclude>-->
<!-- <exclude>cn.navclub:nes4j-bin</exclude>-->
<!-- </excludes>-->
<!-- </artifactSet>-->
<!-- </configuration>-->
<!-- </execution>-->
<!-- </executions>-->
<!-- </plugin>-->
</plugins>
</build>
</project>
10 changes: 4 additions & 6 deletions build/jpackage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,14 @@ java="${JAVA_HOME}/bin/java"
# Check java version
version=$("$java" -version 2>&1 | awk -F '"' '/version/ {print $2}')

# shellcheck disable=SC2071
if [ "$version" -lt "17" ]; then
# shellcheck disable=SC1072
# shellcheck disable=SC2091
# shellcheck disable=SC2116
echo "Java version must >=17"
exit 1
fi

PROGRAM_NAME=nes4j
PROGRAM_NAME="nes4j"
PROGRAM_ICON="icon/nes4j.png"
MAIN_CLASS="cn.navclub.nes4j.app/cn.navclub.nes4j.app.Launcher"

# shellcheck disable=SC2091
$(jpackage -n "$PROGRAM_NAME" -p "$1" -m cn.navclub.nes4j.app/cn.navclub.nes4j.app.Launcher --icon icon/nes4j.png --license-file ../LICENSE --linux-package-name "$PROGRAM_NAME")
$(jpackage -n "$PROGRAM_NAME" -p "$1" -m "${MAIN_CLASS}" --icon "$PROGRAM_ICON" --license-file ../LICENSE --linux-package-name "$PROGRAM_NAME")

0 comments on commit faf159b

Please sign in to comment.