Generate a latest.json file for Tauri auto-updates, supporting multi-platform builds (Windows, macOS Intel/ARM, Linux). This CLI scans your Tauri bundle directory for installers and outputs a valid latest.json for the Tauri Updater.
- Multi-platform detection: Automatically finds
.msi,.exe,.dmg(Intel/ARM),.AppImage,.deb,.rpm, and.tar.gzartifacts. - Interactive Mode: Prompts for missing information (download URL, release notes) if arguments aren't provided.
- Smart platform mapping: Maps artifacts to their respective Tauri platform keys (
windows-x86_64,darwin-aarch64, etc.). - Flexible Versioning: Reads version from
package.json,Cargo.toml, ortauri.conf.json(supports both Tauri 1.0 and 2.0 structures). - Root-run friendly: Can be run from your project root or
src-tauridirectory. - Graceful Signature Handling: Automatically skips artifacts without
.sigfiles (like.dmgwhich Tauri doesn't sign for updates) with a helpful warning. - Verification Support: Optional built-in signature verification against your public key.
cargo install tauri-latest-jsonJust run the command from your Tauri project root. It will prompt you for the download URL and release notes:
tauri-latest-jsonYou can also run from src-tauri and the tool will still auto-detect config and bundle paths.
Provide the download URL base and release notes directly:
tauri-latest-json <download_url_base> <notes...>Example:
tauri-latest-json https://github.com/user/repo/releases/download/v0.4.4 "Fixed security vulnerabilities and improved performance."Use fully non-interactive arguments in CI/CD so jobs fail fast instead of waiting for prompts:
tauri-latest-json "https://github.com/user/repo/releases/download/v0.4.4" "Release notes from CI"Both run modes are supported:
# From project root
tauri-latest-json "https://example.com/downloads" "release notes"
# From src-tauri
cd src-tauri
tauri-latest-json "https://example.com/downloads" "release notes"The tool will:
- Detect Version: Scans
package.json,Cargo.toml, ortauri.conf.json. - Find Artifacts: Searches
target/release/bundlefor installers. - Verify Signatures: Matches installers with their
.sigfiles (skipping.dmgas expected). - Generate Output: Creates a
latest.jsonfile in your current directory, ready for upload.
tauri-latest-json help # Show usage help
tauri-latest-json version # Show versionThe tool prioritizes updater-compatible artifacts:
| Platform | Priority Artifact | Extension Fallbacks |
|---|---|---|
| Windows | .msi |
.exe |
| macOS (Intel) | .app.tar.gz |
.dmg (skipped for updates) |
| macOS (ARM) | .app.tar.gz |
.dmg (skipped for updates) |
| Linux (x64) | .AppImage |
.deb, .rpm, .tar.gz |
| Linux (ARM) | .AppImage |
.deb, .rpm, .tar.gz |
Note: Tauri doesn't generate
.sigfiles for.dmg. This tool will warn you and skip them for the updater JSON, as they aren't used for auto-updates.
- A valid Tauri project with
tauri.conf.json. - A configured
updaterplugin with apubkey. - Built artifacts in
target/release/bundleorsrc-tauri/target/release/bundle.
cargo test
make verifyValidate against a local real Tauri app:
make smoke-real-app
# Or specify a custom directory
REAL_APP_DIR=/path/to/your-app ./scripts/smoke-real-tauri-app.shCould not detect bundle dir: Build your app first sotarget/*/bundleexists.No public key found in tauri.conf.json: Ensure updater pubkey is set inplugins.updater.pubkey(Tauri 2) ortauri.updater.pubkey(Tauri 1).Signature not found for platform ...: Ensure.sigexists for updater artifacts..dmgis expected to be skipped.Argument '...' missing and not in a terminal: Provide full CLI args in CI/non-TTY environments.
MIT — see LICENSE.