Skip to content

Commit 2c9def0

Browse files
committed
better handle pulling jar in run.sh
should fix #100
1 parent f293f0d commit 2c9def0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

linux/run.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
# Check if Java is installed and the version is at least 17
2020
if (( $(java -version 2>&1 | grep -Po '(?<=")[0-9]{2}') >= 17 )); then
21-
latest=$(ls -t CustomLauncherRewrite-*.jar | head -n1)
21+
latest=$(find . -name "CustomLauncherRewrite-*.jar" -type f -printf "%T@ %p\n" | sort -nr | head -n1 | cut -d' ' -f2-)
2222
java -jar "$latest"
2323
else
2424
if command -v notify-send &> /dev/null; then

0 commit comments

Comments
 (0)