ASENA MASK - HOW TO BUILD THE INSTALLER AND RELEASE IT
=======================================================

You do this on your Windows PC (the installer exe can only be built on Windows).

1) BUILD
   Open PowerShell and run (adjust the folder if yours differs):

       powershell -ExecutionPolicy Bypass -File H:\AsenaMask\build\build_all.ps1

   It needs Python 3.10-3.12 on the PATH (any Python is fine, it makes its own build folder).
   It will use the engine code from your local ComfyUI at
   H:\Comfy-Desktop\ComfyUI-Installs\ComfyUI\ComfyUI (the exact version you tested with).
   To use another folder:   ... build_all.ps1 -ComfySource "D:\path\to\ComfyUI"
   To download a version instead:  ... build_all.ps1 -ComfySource "" -ComfyVersion v0.38.1   (only if that path is missing)

   When it finishes, H:\AsenaMask\release contains:
       Asena Mask Setup.exe      <- the small installer people download
       AsenaMask-app.zip         <- the app itself (about 100-150 MB), the installer fetches this
       AsenaMask-app.sha256.txt

2) TEST ON YOUR OWN PC FIRST (no hosting needed)
   Keep both files in the same folder and double-click "Asena Mask Setup.exe".
   If AsenaMask-app.zip is next to it, the installer uses that file.
   Best test: create a second Windows user (or use another PC with an NVIDIA card) so nothing of your
   dev setup can leak in. Installed Asena Mask uses ONLY its own folder:
       %LOCALAPPDATA%\Programs\Asena Mask\   (runtime, engine, model)
   It does not use your H:\ ComfyUI or your Python/PyTorch.

3) HOST IT SO EVERYONE CAN DOWNLOAD
   - Upload AsenaMask-app.zip somewhere with a stable direct link. Easiest and free: a GitHub release
     (https://github.com/YOU/REPO/releases) - the link looks like
     https://github.com/YOU/REPO/releases/download/v1.0.0/AsenaMask-app.zip
   - Open installer\config.py and set PACKAGE_URL to that link (optionally PACKAGE_SHA256 from the .sha256.txt file).
   - Run build_all.ps1 again so the installer knows the link.
   - Give people ONLY "Asena Mask Setup.exe" (upload it to the same release or your website).
     What it downloads at install time: the app package (your link), Python (python.org),
     PyTorch GPU libraries (download.pytorch.org), the AI model (huggingface.co). About 6 GB in total.

4) WINDOWS WARNINGS (normal for new free apps)
   Because the exe is not code-signed, Windows SmartScreen may say "Windows protected your PC".
   Users click "More info" -> "Run anyway". A code-signing certificate removes this (paid, optional, later).
   Some antivirus tools flag brand-new unsigned exes; you can submit the file to them as a false positive.

5) LICENCES (GPL)
   build\THIRD_PARTY_NOTICES.txt is included in the package (LICENSES folder). Replace SOURCE_URL_HERE in it
   with the page where you publish the source code (asenamask folder + installer + build scripts), then rebuild.

6) UPDATES
   Change APP_VERSION in asenamask\__init__.py, installer\config.py and the two build\version_*.txt files,
   rebuild, upload the new zip + installer. Running the installer on a PC that already has Asena Mask offers
   "Repair / reinstall", which refreshes the app and keeps the model.

UNINSTALL
   Windows Settings -> Apps -> Asena Mask -> Uninstall (or "Uninstall Asena Mask.exe" in the install folder).
   Your settings stay in %APPDATA%\AsenaMask.

FILES (for reference)
   installer\core.py       what the installer does (download, set up, verify, shortcuts)
   installer\setup_ui.py   the installer window
   installer\config.py     links and version
   build\build_all.ps1     one-click build
