Skip to content

feat(portable): support portable windows x64 distribution with isolated data folder - #40

Merged
shadowmkj merged 2 commits into
mainfrom
feat/portable-windows
Nov 14, 2026
Merged

shadowmkj merged 2 commits into
mainfrom
feat/portable-windows

Conversation

@shadowmkj

Copy link
Copy Markdown
Owner

Summary

This change introduces support for a portable Windows x64 distribution that relies on an isolated local data directory. It dynamically detects portable execution environments, redirects Tauri root configuration directories, and automates the creation and uploading of portable ZIP releases in the GitHub Actions workflow.

Closes #36

Key Changes

  • Portable Directory Detection (watcher.rs): Implemented get_portable_data_dir and get_portable_data_dir_from to detect local data/ directories adjacent to the executable or via the SCRIBL_PORTABLE_DATA_DIR environment variable.
  • Tauri App Directory Override (lib.rs): Updated the app initialization to dynamically override Tauri root application paths if a portable data directory is found, ensuring self-contained storage.
  • Release Automation (release.yml): Added a GitHub Actions workflow step to package the Windows x64 executable, LICENSE, README, and structured data template folders into a .zip archive and upload it to the release.
  • Unit Testing: Added comprehensive unit test suites covering portable path resolution, environment variable overrides, and configuration directory paths.

Verification & Testing

  • Automated Tests Run: Executed cargo unit tests for portable data directory detection and configuration overrides:
    cargo test --manifest-path src-tauri/Cargo.toml
  • Manual Verification: Verified that running the executable adjacent to a data folder correctly reroutes configuration files, themes, and webview cache paths to the isolated directory.

…ed data folder

- Detect portable mode at startup when data/ directory exists adjacent to executable
- Redirect Lua configuration and custom themes to data/config/
- Configure Tauri v2 AppDirectoriesOverride::Root to isolate webview cache and local storage into data/
- Add release workflow step on windows-latest to package and upload scribl_${VERSION}_x64_portable.zip
@shadowmkj
shadowmkj merged commit 99261d9 into main Nov 14, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[REQUEST] a portable x64 version for windows in .zip file

1 participant