Rename app to EasyView and make APK build cross-platform
- App display name -> EasyView (Android label, PWA manifest, page titles, about/guide text, APK artifact name) - scripts/build-apk.mjs: auto-detect JDK/SDK/Gradle toolchain instead of hardcoded Windows paths; pick highest build-tools; platform 34 fallback; path.delimiter classpaths; npm run build without cmd.exe on POSIX - Add build-apk.sh one-shot Linux build wrapper (loads ven env + keystore) - Signing keystore renamed to easyview.jks (alias easyview), env vars EASYVIEW_KEYSTORE_PASS / EASYVIEW_KEY_PASS
This commit is contained in:
Executable
+24
@@ -0,0 +1,24 @@
|
||||
#!/usr/bin/env bash
|
||||
# 一键构建 EasyView APK(Linux / 本工作区 ven 工具链)
|
||||
# 用法:./build-apk.sh
|
||||
set -euo pipefail
|
||||
|
||||
here="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
ven="$(cd "$here/../ven" && pwd)"
|
||||
|
||||
source "$ven/node-env.sh"
|
||||
export npm_config_cache="$ven/npm"
|
||||
export ANDROID_HOME="$ven/android-sdk"
|
||||
export ANDROID_SDK_ROOT="$ANDROID_HOME"
|
||||
|
||||
# 签名口令:优先取 android/keystore/.env.keystore(已 gitignore)
|
||||
if [[ -f "$here/android/keystore/.env.keystore" ]]; then
|
||||
set -a
|
||||
# shellcheck disable=SC1091
|
||||
. "$here/android/keystore/.env.keystore"
|
||||
set +a
|
||||
fi
|
||||
: "${EASYVIEW_KEYSTORE_PASS:?未设置签名口令:请在 android/keystore/.env.keystore 中写入 EASYVIEW_KEYSTORE_PASS}"
|
||||
|
||||
cd "$here"
|
||||
node scripts/build-apk.mjs
|
||||
Reference in New Issue
Block a user