diff --git a/CLAUDE.md b/CLAUDE.md index 513074b..151da5c 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -24,50 +24,11 @@ Tests use Node.js directly — no test runner or build step needed. ### Run / build (Electron) ```sh -nix-shell --run "cordova run electron" # dev run +cordova run electron # dev run +cordova build electron --release --verbose # release build ``` -Release build produces an AppImage (Linux) in two steps — cordova-electron bundles electron-builder v24 which ignores the Linux target, so electron-builder v26 from devDependencies is called directly: - -```sh -nix-shell --run "cordova build electron --release" # prepare platform -nix-shell --run "node_modules/.bin/electron-builder --linux AppImage --config res/electron/build.json" -# output: platforms/electron/build/BioLab-1.0.0.AppImage -``` - -### Build release APK (Android) - -Signing keys are managed via agenix (`android-signing-env`). Use `--packageType=apk` to force APK output instead of AAB: - -```sh -android-signing-env python3 -c " -import json, os -cfg = {'android': {'release': { - 'keystore': os.environ['ANDROID_KEYSTORE_PATH'], - 'keystoreType': 'pkcs12', - 'alias': os.environ['ANDROID_KEY_ALIAS'], - 'storePassword': os.environ['ANDROID_KEYSTORE_PASSWORD'], - 'password': os.environ['ANDROID_KEY_PASSWORD'] -}}} -open('/tmp/biolab-build.json','w').write(__import__('json').dumps(cfg)) -" -nix-shell --run "ANDROID_HOME=\$HOME/Android/Sdk ANDROID_SDK_ROOT=\$HOME/Android/Sdk \ - GRADLE_USER_HOME=\$(pwd)/.gradle \ - cordova build android --release --buildConfig /tmp/biolab-build.json -- --packageType=apk" -rm /tmp/biolab-build.json -# output: platforms/android/app/build/outputs/apk/release/app-release.apk -``` - -### Build release .exe (Windows VM) - -```sh -# VM: user@192.168.122.187, cordova global at C:\Users\User\AppData\Roaming\npm\cordova.cmd -ssh user@192.168.122.187 "cd C:\\Users\\user\\BioLab && git pull && C:\\Users\\User\\AppData\\Roaming\\npm\\cordova.cmd build electron --release" -scp "user@192.168.122.187:C:/Users/user/BioLab/platforms/electron/build/BioLab Setup 1.0.0.exe" /tmp/ -# output: /tmp/BioLab Setup 1.0.0.exe -``` - -### Run on Android (dev) +### Run on Android ```sh # Set up environment first (or source env.sh): @@ -96,6 +57,7 @@ www/ search.js — orchestrates everything: builds ODE functions (model × Pirt coupling), runs PSO per model, renders Plotly charts, computes AIC, sorts results rrandom.js — Math.random wrapper used by PSO + solve.js — standalone legacy helper (not imported by search.js) tests/ demo.mjs — smoke test: PSO converges to a finite error synthetic-search.mjs — accuracy test: PSO recovers known Monod params from synthetic data @@ -120,3 +82,4 @@ www/ - External CDN dependencies: KaTeX (math rendering), Plotly (charts). Both are loaded in `index.html`; `search.js` assumes `Plotly` and `katex` are globals. - The `Objective` constructor detects column order from header keywords (Portuguese and English), so column order in the data table matters only when headers are absent or unrecognized. - `PSO` uses `Math.random` directly — `synthetic-search.mjs` patches it with a deterministic LCG for reproducible test results. +- `solve.js` is a legacy standalone function that references globals (`RK4`, `Plotly`, `document`) and is not imported anywhere in the current codebase. diff --git a/README.md b/README.md index 912850f..753aa97 100644 --- a/README.md +++ b/README.md @@ -2,13 +2,7 @@ Ferramenta web para estimativa de parâmetros cinéticos de crescimento microbiano e consumo de substrato. -Acesse em: **[biolab.tadix.dev](https://biolab.tadix.dev)** — ou baixe o app para desktop/Android: - -| Plataforma | Download | -|---|---| -| Linux (AppImage) | [BioLab-1.0.0.AppImage](https://git.tadix.dev/ltadeu6/BioLab/releases/tag/v1.0.0) | -| Windows (instalador) | [BioLab-Setup-1.0.0.exe](https://git.tadix.dev/ltadeu6/BioLab/releases/tag/v1.0.0) | -| Android (APK) | [BioLab-1.0.0.apk](https://git.tadix.dev/ltadeu6/BioLab/releases/tag/v1.0.0) | +Acesse em: **[biolab.tadix.dev](https://biolab.tadix.dev)** ## Como funciona diff --git a/package.json b/package.json index 2d89ec8..ca301e2 100644 --- a/package.json +++ b/package.json @@ -24,23 +24,14 @@ ] }, "build": { - "appId": "dev.tadix.biolab", + "appId": "com.tadeu.biolab", "productName": "BioLab", "directories": { - "buildResources": "res" - }, - "linux": { - "target": "AppImage", - "icon": "res/icon.png", - "category": "Science" + "buildResources": "resources" }, "win": { "target": "nsis", - "icon": "res/icon.ico" - }, - "nsis": { - "oneClick": false, - "allowToChangeInstallationDirectory": true + "icon": "resources/icon.ico" } } } \ No newline at end of file diff --git a/res/electron/build.json b/res/electron/build.json index 2066ba4..76526c4 100644 --- a/res/electron/build.json +++ b/res/electron/build.json @@ -2,9 +2,7 @@ "appId": "dev.tadix.biolab", "productName": "BioLab", "directories": { - "buildResources": "res", - "app": "platforms/electron/www", - "output": "platforms/electron/build" + "buildResources": "res" }, "linux": { "target": "AppImage",