能否使用Squirrel.Windows为WinJS Metro应用安装及推送更新?
Can Squirrel.Windows Work with WinJS-Based Windows 8/10 Metro Apps?
Great question—let’s cut straight to the chase here: No, Squirrel.Windows isn’t designed to work with WinJS Metro-style apps, and trying to force it would run into fundamental platform restrictions. Here’s the breakdown:
- Core Design Mismatch: Squirrel is built exclusively for traditional Win32/.NET desktop apps (think WPF, WinForms, or console apps). It handles updates by modifying app installation directories, managing Start Menu shortcuts, and running system-level operations that are completely off-limits to sandboxed Metro apps.
- Metro App Sandbox Constraints: WinJS Metro apps run in a restricted sandbox environment. Their installation folders are protected, and they can’t modify their own files or interact with system resources the way Squirrel requires. The Windows platform already manages updates for these apps natively via the Microsoft Store (or sideloading policies if you’re not publishing to the Store).
- Your Better Alternatives:
- If you’re publishing to the Microsoft Store: Let the Store handle updates automatically—users get prompts to install new versions, and you don’t have to build custom logic.
- If you’re sideloading apps: Use tools like the built-in App Installer, or implement a sandbox-compliant custom update flow (e.g., using background tasks to check for new app packages on your server, then prompting users to download and install them via the system’s app installation APIs).
Just to clarify: If you were building a WinJS-based desktop app (not Metro-style), Squirrel could potentially work with some extra setup, but that’s not what you’re asking about here.
内容的提问来源于stack exchange,提问作者avinash
相关产品推荐
相关产品推荐

