aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorKostya <mail@sartin.in>2026-08-18 18:19:50 +0300
committerKostya <mail@sartin.in>2026-08-18 18:19:50 +0300
commit755d2265054e5140e82d322681566c3034583c95 (patch)
tree0220f9d04affa03fabf3c2bc68c51c01ee1475d9 /tools
parent9dab2b3d624ecae08439532157fb8b9805fe9274 (diff)
downloadguess-market-755d2265054e5140e82d322681566c3034583c95.tar.gz
guess-market-755d2265054e5140e82d322681566c3034583c95.tar.xz
guess-market-755d2265054e5140e82d322681566c3034583c95.zip
Break down purchase receipts by cost/commission, harden XML validation and state I/O
Adds a full pre-load validation pass for GM XML seeds (ids, names, options, commission, LMSR liquidity), replaces IO.print with System.out, and surfaces detailed error messages across load/save commands instead of generic failures.
Diffstat (limited to 'tools')
-rw-r--r--tools/_util.sh7
-rw-r--r--tools/package.sh2
2 files changed, 8 insertions, 1 deletions
diff --git a/tools/_util.sh b/tools/_util.sh
index 4650616..fa7e3b5 100644
--- a/tools/_util.sh
+++ b/tools/_util.sh
@@ -15,7 +15,12 @@ RUNTIME_LIB_DIRS="pico jaxb gson"
15 15
16MAIN_CLASS="market.guess.ui.console.App" 16MAIN_CLASS="market.guess.ui.console.App"
17 17
18JAVA_HOME_DIR=$(java -XshowSettings:properties -version 2>&1 | sed -n 's/^ *java\.home = //p') 18JAVA_HOME_DIR=$(java -XshowSettings:properties -version 2>&1 | tr -d '\r' | sed -n 's/^ *java\.home = //p')
19case "$(uname -s)" in
20 CYGWIN*|MINGW*|MSYS*)
21 JAVA_HOME_DIR=$(cygpath -u "$JAVA_HOME_DIR" 2>/dev/null || echo "$JAVA_HOME_DIR")
22 ;;
23esac
19JAR="$JAVA_HOME_DIR/bin/jar" 24JAR="$JAVA_HOME_DIR/bin/jar"
20[ -x "$JAR" ] || JAR="$JAVA_HOME_DIR/bin/jar.exe" 25[ -x "$JAR" ] || JAR="$JAVA_HOME_DIR/bin/jar.exe"
21if [ ! -x "$JAR" ]; then 26if [ ! -x "$JAR" ]; then
diff --git a/tools/package.sh b/tools/package.sh
index 5877444..a85ee6c 100644
--- a/tools/package.sh
+++ b/tools/package.sh
@@ -60,6 +60,8 @@ java -jar "%~dp0ui-console.jar"
60if errorlevel 1 pause 60if errorlevel 1 pause
61EOF 61EOF
62 62
63[ -f README.pdf ] && cp README.pdf "$DIST/"
64
63echo "=== Manifest as it actually landed in the jar ===" 65echo "=== Manifest as it actually landed in the jar ==="
64# Cheapest check that prevents a Level-0: if Main-Class or Class-Path didn't 66# Cheapest check that prevents a Level-0: if Main-Class or Class-Path didn't
65# survive, it surfaces here instead of on the grader's machine. 67# survive, it surfaces here instead of on the grader's machine.