When to use this skill
ALWAYS use this skill when the user mentions:
- Upgrading from Tauri v1 to v2 / Upgrading from v1 to v2
- Migrating from v2 beta to v2 stable / Migrating from v2 beta to stable
- Breaking changes in config or permissions / Config or permission changes
Trigger phrases include:
- "migrate", "upgrade", "breaking changes", "v1 to v2"
- "upgrade", "migration", "config changes", "permission changes"
How to use this skill
- Identify current version and target / Confirm current version and target version
- Review breaking changes across config, plugins, permissions / Review change points
- Update tauri.conf.json and plugin layouts / Update config and plugin locations
- Migrate capabilities/default.json and scopes / Migrate capabilities and scopes
- Validate IPC, CSP, and runtime behavior / Validate IPC, CSP, and runtime behavior
Outputs
- Migration checklist / Migration checklist
- Updated config mapping / Updated config mapping
- Post-upgrade validation plan / Post-upgrade validation plan
Scope
- Boundary: Version migration and validation only / Migration and validation only
- Key points: Config structure and capability system changes / Config and permission system
- Out of scope: feature redesign / Does not include feature redesign
References
- https://v2.tauri.app/llms.txt
- https://v2.tauri.app/start/migrate/
- https://v2.tauri.app/start/migrate/from-tauri-1/
- https://v2.tauri.app/start/migrate/from-tauri-2-beta/
Keywords
tauri upgrade, migrate, v2, breaking changes, config migration, upgrade, migration, config changes
Common Pitfalls (Gotchas)
- Version compatibility: Note the compatibility between framework versions and dependency libraries; APIs may differ across versions
- Config file format: Config file format errors are the most common issue; it is recommended to use the editor's syntax checking
- Environment variables: Ensure all necessary environment variables are set correctly, and do not hardcode sensitive information
- Dependency conflicts: When multiple versions coexist, watch for dependency conflicts and use a lock file to pin versions
- Performance pitfalls: Pay attention to performance optimization in large-data scenarios and avoid common issues such as N+1 queries
Usage flow
Step 1: Environment preparation
Ensure the development environment has the necessary dependencies and tools installed.
Step 2: Config initialization
Perform basic configuration according to project requirements.
Step 3: Using core features
Implement core features according to the example code.
Step 4: Test validation
Run tests to ensure functionality works properly.
Step 5: Deployment and release
After completing development, proceed with deployment and monitoring.