Packaging & Cloudflare R2 Release Guide
ShibaPPT uses Inno Setup 6 to build per-user (no-UAC) Windows installers and Cloudflare R2 (scripts\publish-r2.ps1) to distribute auto-update manifests (version.json), setup binaries, and on-demand heavy asset archives.
1. Installer Architecture (Inno Setup/Setup.iss)
To avoid classic VSTO deployment pitfalls under C:\Program Files (permission errors when writing caches, UAC prompts, or blocked satellite DLLs), Setup.iss applies five key engineering practices:
- Per-User No-UAC Installation:
- Sets
PrivilegesRequired=lowestand installs by default into%LocalAppData%\ShibaPPT. - Registers the VSTO add-in under
HKCU\SOFTWARE\Microsoft\Office\PowerPoint\Addins\shibappt(plusHKEY_CURRENT_USER_64on 64-bit Windows) withLoadBehavior = 3andManifest = "{app}\shibappt.vsto|vstolocal".
- Sets
- Automatic NTFS Zone Unblocking (
UnblockInstalledFiles):- Runs
Unblock-Fileacross all installed*.dll,*.exe, and*.vstofiles (clearingZone.Identifieralternate data streams) so .NET CAS policy never blocks downloaded assemblies.
- Runs
- VSTO Security Inclusion (
AddToTrustedLocations):- Registers
{app}\underHKCU\SOFTWARE\Microsoft\VSTO\Security\Inclusion\ShibaPPT.
- Registers
.vbaFile Association:- Registers
HKCU\Software\Classes\.vba->ShibaPPT.VbaScriptpointing toShibaVbaRunner.exe, enabling double-click execution of.vbascripts against the active presentation.
- Registers
- Lean Installer Footprint:
- Excludes
Tools\PaddleSegSharp\*,Tools\PPTOCR\*,FontTool.exe, and*.pdbsymbols from[Files]. Heavy AI models and font utilities are fetched on demand from Cloudflare R2 viaRemoteAssetManagerinto%LocalAppData%\ShibaPPT\Assets.
- Excludes
2. Four-Step Release Workflow
Step 1: Bump Version & Run Full Release Build
Update AssemblyVersion and AssemblyFileVersion in Properties\AssemblyInfo.cs (e.g., 1.0.0.29), then run a full Release build:
powershell -ExecutionPolicy Bypass -File scripts\build.ps1 -Configuration ReleaseStep 2: Compile the Inno Setup Installer
Invoke ISCC.exe explicitly with /DAppVersion matching the compiled assembly (or run Inno Setup\build.bat, which auto-increments the 4th version segment in AssemblyInfo.cs and compiles):
& "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" /DAppVersion=1.0.0.29 "Inno Setup\Setup.iss"This produces Inno Setup\Output\shibappt-setup-v1.0.0.29.exe.
Step 3: Update Inno Setup\Output\version.json
Ensure version and the filename at the end of downloadUrl match the newly built installer (publish-r2.ps1 validates both):
{
"version": "1.0.0.29",
"downloadUrl": "https://dl.shibappt.com/shibappt-setup-v1.0.0.29.exe",
"releaseNotes": "1. Added Cross-Page Sync Panel\n2. Improved WebView2 multi-window memory cleanup",
"publishedAt": "2026-11-27"
}Step 4: Publish to Cloudflare R2 (scripts\publish-r2.ps1)
Prerequisites: npm install -g wrangler, authenticated via wrangler login, and R2 bucket name configured in .r2-bucket or $env:SHIBAPPT_R2_BUCKET.
# 1. Dry-run first to inspect resolved paths, byte size, and wrangler commands
powershell -ExecutionPolicy Bypass -File scripts\publish-r2.ps1 -DryRun
# 2. Upload installer + version.json and verify live CDN endpoints
powershell -ExecutionPolicy Bypass -File scripts\publish-r2.ps1publish-r2.ps1 automatically:
- Verifies version consistency between
version.json,downloadUrl, and the non-empty.exebinary; - Uploads
shibappt-setup-v<Version>.exe(application/octet-stream); - Uploads
version.jsonwithCache-Control: no-cache, max-age=60; - Performs live HTTP
GETandHEADchecks againsthttps://dl.shibappt.comto confirm the live version string andContent-Lengthmatch byte-for-byte.
3. Client Auto-Update Flow (AppUpdateManager)
Core\Utils\AppUpdateManager.cs consumes the R2 endpoints inside PowerPoint:
- Fetches
https://dl.shibappt.com/version.json?t=<timestamp>; - Compares against
Assembly.GetExecutingAssembly().GetName().Version; - When an update is confirmed by the user, streams the setup
.exeto%TEMP%with aShibaProgressWebWindowprogress bar and launches the installer.
