diff --git a/.github/workflows/build-nms.yml b/.github/workflows/build-nms.yml
index 01ee7f68f..5d1a1209e 100644
--- a/.github/workflows/build-nms.yml
+++ b/.github/workflows/build-nms.yml
@@ -18,8 +18,10 @@ jobs:
with:
lookup-only: true
path: nms-build/.m2
- key: scenamatica-nms
- restore-keys: scenamatica-nms
+ key: nms-maven
+ restore-keys: nms-maven
+ - name: Debug Cache Hit
+ run: "echo Cache hit: ${{ steps.check.outputs.cache-hit }}, ${{ steps.check.outputs.cache-hit == 'true'}}"
build-nms:
name: Build NMS with NMSAction
needs: check-whether-has-to-build
diff --git a/.github/workflows/build-scenamatica.yml b/.github/workflows/build-scenamatica.yml
index c8946a9d1..1445f03ef 100644
--- a/.github/workflows/build-scenamatica.yml
+++ b/.github/workflows/build-scenamatica.yml
@@ -28,15 +28,15 @@ jobs:
uses: actions/cache@v4
with:
path: nms-build/.m2
- key: scenamatica-nms
- restore-keys: scenamatica-nms
+ key: nms-maven
+ restore-keys: nms-maven
- name: Deploy NMS cache
if: steps.maven-cache.outputs.cache-hit != 'true'
run: |
mv -f nms-build/.m2/repository/repository $HOME/.m2/ -v
- name: Build with Maven
run: |
- ./Scenamatica/build -D"jar.finalName=Scenamatica" -P debug
+ ./Scenamatica/build.sh -D"jar.finalName=Scenamatica" -P debug
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
diff --git a/.github/workflows/docs-deploy.yml b/.github/workflows/docs-deploy.yml
index 1601fe333..b5bd09042 100644
--- a/.github/workflows/docs-deploy.yml
+++ b/.github/workflows/docs-deploy.yml
@@ -6,6 +6,7 @@ on:
- main
paths:
- docs/**
+ workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.event.number || github.sha }}
diff --git a/Bookkeeper/core/pom.xml b/Bookkeeper/core/pom.xml
index 5d49bac85..6c4580321 100644
--- a/Bookkeeper/core/pom.xml
+++ b/Bookkeeper/core/pom.xml
@@ -63,6 +63,20 @@
+
+
+ papermc-repo
+ https://repo.papermc.io/repository/maven-public/
+
+
+ sonatype
+ https://oss.sonatype.org/content/groups/public/
+
+
+ jitpack
+ https://jitpack.io
+
+
org.kunlab.scenamatica.bookkeeper
@@ -70,12 +84,6 @@
1.0.0
compile
-
- org.kunlab.scenamatica
- ScenamaticaPlugin
- 1.4.1
- provided
-
com.destroystokyo.paper
paper-api
diff --git a/Bookkeeper/run.bat b/Bookkeeper/run.bat
deleted file mode 100644
index 64b6ef880..000000000
--- a/Bookkeeper/run.bat
+++ /dev/null
@@ -1,14 +0,0 @@
-@echo off
-
-REM 1. Check if Bookkeeper.jar exists
-IF NOT EXIST "cli\target\Bookkeeper.jar" (
- echo Building Bookkeeper.jar...
- mvn package
- IF %ERRORLEVEL% NEQ 0 (
- echo Build failed.
- exit /b 1
- )
-)
-
-REM 2. Run the jar file
-java -jar cli\target\Bookkeeper.jar %*
diff --git a/Scenamatica/build.bat b/Scenamatica/build.bat
deleted file mode 100644
index 809d20b65..000000000
--- a/Scenamatica/build.bat
+++ /dev/null
@@ -1,4 +0,0 @@
-@echo off
-
-mvn install --file ../Bookkeeper/pom.xml
-mvn package --file pom.xml "$@"
diff --git a/docs/build-references.bat b/docs/build-references.bat
deleted file mode 100644
index a229fc9f6..000000000
--- a/docs/build-references.bat
+++ /dev/null
@@ -1,41 +0,0 @@
-@echo off
-
-REM 1. Build Scenamatica.jar
-cd ..\Scenamatica
-call ./build -D"jar.finalName=Scenamatica" -P release
-
-if %ERRORLEVEL% NEQ 0 (
- echo Build failed.
- exit /b 1
-)
-
-REM 2. Build ledger
-cd ..\Bookkeeper
-call run -o dist -cp "%paper:1.16.5" -i ..\Scenamatica\ScenamaticaPlugin\target\Scenamatica.jar
-
-if %ERRORLEVEL% NEQ 0 (
- echo Build failed.
- exit /b 1
-)
-
-REM 3. Build templating-tools
-set CWD=%cd%
-cd ..\Bookkeeper\templating-tools
-call pnpm start -t %CWD%\bookkeeper-templates -e .mdx -o %CWD%\references %CWD%\dist\ledger.zip
-
-if %ERRORLEVEL% NEQ 0 (
- echo Build failed.
- cd %CWD%
- exit /b 1
-)
-cd %CWD%
-
-# 4. Copy schemas to static directory
-mkdir static/schemas
-
-## 4.1 Copy schemas
-xcopy dist\* static\schemas /s
-
-## 4.2 Remove LICENSE and README.md files
-del static/schemas/LICENSE
-del static/schemas/README.md
diff --git a/docs/build-references.sh b/docs/build-references.sh
index ff454ee2f..601516bb6 100644
--- a/docs/build-references.sh
+++ b/docs/build-references.sh
@@ -1,7 +1,10 @@
-#!/bin/bash
+#!/bin/sh
# 1. Build Scenamatica.jar
-../Scenamatica/build -D"jar.finalName=Scenamatica" -P release
+cd ../Scenamatica
+chmod +x build.sh
+
+./build.sh -D"jar.finalName=Scenamatica" -P release
if [ $? -ne 0 ]; then
echo "Build failed."
@@ -9,13 +12,17 @@ if [ $? -ne 0 ]; then
fi
# 2. Build ledger
-../Bookkeeper/run -o dist -cp "\$paper:1.16.5" -i ../Scenamatica/ScenamaticaPlugin/target/Scenamatica.jar
+cd ../Bookkeeper
+chmod +x run.sh
+./run.sh -o dist -cp "\$paper:1.16.5" -i ../Scenamatica/ScenamaticaPlugin/target/Scenamatica.jar
if [ $? -ne 0 ]; then
echo "Build failed."
exit 1
fi
+cd ../docs
+
# 3. Build templating-tools
CWD=$(pwd)
cd ../Bookkeeper/templating-tools
diff --git a/docs/package.json b/docs/package.json
index bb08cbd63..48b7b3cfc 100644
--- a/docs/package.json
+++ b/docs/package.json
@@ -5,7 +5,7 @@
"scripts": {
"docusaurus": "docusaurus",
"start": "docusaurus start",
- "build": "./build-references && pnpm run build:site",
+ "build": "./build-references.sh && pnpm run build:site",
"build:site": "docusaurus build",
"swizzle": "docusaurus swizzle",
"deploy": "docusaurus deploy",