Tauri Skill
🤖 AI Integration Guide: Send this page link to AI for automatic integration guidance
Quick Information
- Application Type: Tauri
- Skill Version: 1.0.0
- Integration Difficulty: ⭐⭐ (Easy)
- Estimated Time: 10 minutes
🎯 Integration Steps
Step 1: Install Plugin
bash
npm install @tauri-apps/plugin-updaterStep 2: Configure tauri.conf.json
Copy the following configuration to tauri.conf.json:
json
{
"plugins": {
"updater": {
"dangerousInsecureTransportProtocol": true,
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IDY4QjBGNEM4NjUyMUNGRjAKUldUd3p5Rmx5UFN3YUN1UkFMK05DdWR4VjA1eDRybkxJNzMreURNbHZ4VFhtSk54UTVMWVg4NnAK",
"endpoints": [
"https://api.upgrade.toolsetlink.com/v1/tauri/upgrade?tauriKey=YOUR_TAURI_KEY&versionName={{current_version}}&appointVersionName=&devModelKey=&devKey=&target={{target}}&arch={{arch}}"
],
"windows": {
"installMode": "passive"
}
}
}
}⚠️ Note: Replace YOUR_TAURI_KEY with your actual Tauri Key
Step 3: Add Update Check Code
Add the following code to your Tauri application:
typescript
import { check } from '@tauri-apps/plugin-updater';
async function checkForUpdates() {
try {
const update = await check({
timeout: 5000,
headers: {
'X-AccessKey': 'YOUR_ACCESS_KEY',
},
});
if (update?.available) {
console.log('New version found:', update.version);
await update.downloadAndInstall();
}
} catch (error) {
console.error('Failed to check for updates:', error);
}
}⚠️ Note: Replace YOUR_ACCESS_KEY with your actual Access Key
Step 4: Set Permissions
Add the following to src-tauri/capabilities/default.json:
json
{
"permissions": [
"updater:default",
"process:default"
]
}🤖 AI Integration
Send this page link to AI, for example:
Please help me integrate application upgrade, here's the Skill link:
https://www.toolsetlink.com/en/upgrade/skill/tauriAI will automatically:
- Identify the application type as Tauri
- Retrieve configuration information and code examples
- Guide you to replace placeholders (YOUR_TAURI_KEY, etc.)
- Verify configuration correctness
- Complete integration testing
📋 Complete Example
View complete example project: tauri-demo
❓ FAQ
Q: How to get Tauri Key?
A: Log in to UpgradeLink dashboard, create a Tauri application to obtain it.
Q: How to get Access Key?
A: Log in to UpgradeLink dashboard, obtain it from the key management page.
Q: What if update fails?
A: Check network connection and configuration, or contact AI for help.