Tauri v2 Cheatsheet — The Commands I Use on Every Project
All tests run on an 8-year-old MacBook Air. All results from shipping 7 Mac apps as a solo developer. No sponsored opinion.
After 7 Tauri apps, I type the same commands constantly. Here's the reference I wish existed when I started.
Project setup
Development
Building
Plugins
This updates both
Permissions (tauri.conf.json)
Tauri v2 requires explicit permission declarations. If a command silently does nothing, check permissions first.
Common Rust patterns
Notarization (macOS)
Debugging
The most useful thing I learned
When a Tauri command silently fails: check the browser console first (
Silent failures in Tauri are almost always a permissions issue or a missing
TL;DR: Quick Tauri v2 command reference:
If this was useful, a ❤️ helps more than you'd think — thanks!
HiyokoAutoSync | X → @hiyoyok
via DEV Community: rust (author: hiyoyo)
All tests run on an 8-year-old MacBook Air. All results from shipping 7 Mac apps as a solo developer. No sponsored opinion.
After 7 Tauri apps, I type the same commands constantly. Here's the reference I wish existed when I started.
Project setup
# New project
npm create tauri-app@latest
# Add to existing project
npm install --save-dev @tauri-apps/cli
npx tauri init
Development
# Dev mode (hot reload)
npm run tauri dev
# Dev with specific log level
RUST_LOG=debug npm run tauri dev
# Dev with backend logs visible
npm run tauri dev 2>&1 | grep -v "^$"
Building
# Standard build
npm run tauri build
# Universal binary (Intel + Apple Silicon)
npm run tauri build -- --target universal-apple-darwin
# Debug build (faster, no optimization)
npm run tauri build -- --debug
Plugins
npm run tauri add global-shortcut
npm run tauri add fs
npm run tauri add shell
npm run tauri add notification
This updates both
Cargo.toml and the plugin registration. Faster than doing it manually.Permissions (tauri.conf.json)
{
"app": {
"security": {
"capabilities": [
{
"identifier": "main-capability",
"description": "Main window capabilities",
"windows": ["main"],
"permissions": [
"fs:read-all",
"fs:write-all",
"shell:execute",
"global-shortcut:allow-register"
]
}
]
}
}
}
Tauri v2 requires explicit permission declarations. If a command silently does nothing, check permissions first.
Common Rust patterns
// Get app data directory
let data_dir = app.path().app_data_dir().unwrap();
// Emit event to frontend
app_handle.emit("event-name", payload).ok();
// Get window
let window = app.get_webview_window("main").unwrap();
// App state
app.manage(MyState::new());
let state = app.state::<MyState>();
Notarization (macOS)
# Submit for notarization
xcrun notarytool submit app.dmg \
--apple-id YOUR_APPLE_ID \
--team-id YOUR_TEAM_ID \
--password YOUR_APP_PASSWORD \
--wait
# Staple after notarization
xcrun stapler staple app.dmg
Debugging
# Check what's in the bundle
unzip -l target/release/bundle/macos/App.app/Contents/MacOS/App
# Verify notarization
spctl -a -v App.app
# Check entitlements
codesign -d --entitlements - App.app
The most useful thing I learned
When a Tauri command silently fails: check the browser console first (
Cmd+Option+I in dev mode), then check RUST_LOG output, then check permissions.Silent failures in Tauri are almost always a permissions issue or a missing
#[tauri::command] registration.TL;DR: Quick Tauri v2 command reference:
npm run tauri dev / tauri build -- --target universal-apple-darwin / tauri add <plugin>. Silent command failures? Check DevTools console → RUST_LOG → permissions in that order. Almost always a missing permission or unregistered command.If this was useful, a ❤️ helps more than you'd think — thanks!
HiyokoAutoSync | X → @hiyoyok
via DEV Community: rust (author: hiyoyo)
BoxAgnts Tool System (6) — Multi-Provider Adaptation and the Agent Query Loop
via DEV Community: rust (author: Guyoung Studio)
via DEV Community: rust (author: Guyoung Studio)
Telegraph
BoxAgnts Tool System (6) — Multi-Provider Adaptation and the…
BoxAgnts' tool system, from the bottom-level WASM sandbox to the top-level Tool trait, has solved "how tools run safely." But tools ultimately need to be called by AI models — which introduces two engineering problems: the complete incompatibility of API…
Bun rewrote itself from Zig to Rust in 9 days with an LLM. That's terrifying.
via DEV Community: rust (author: Aditya Agarwal)
via DEV Community: rust (author: Aditya Agarwal)
Telegraph
Bun rewrote itself from Zig to Rust in 9 days with an LLM. T…
It took nine days to rewrite all of Bun from Zig to Rust using an LLM and get the new code to the point where I could merge it. I saw that and my reaction was not “cool.” It was “oh no.” Let me be clear. The speed isn't what scares me. The confidence is.…
RustRover Autocomplete Issues with Macro-Heavy Assertion Libraries Solved by RXpect's Trait-Based Approach
via DEV Community: rust (author: Sergey Boyarchuk)
via DEV Community: rust (author: Sergey Boyarchuk)
Telegraph
RustRover Autocomplete Issues with Macro-Heavy Assertion Lib…
Introduction Rust's assertion libraries have long been a double-edged sword for developers. While macros provide syntactic sugar and concise syntax, their heavy use introduces a critical friction point: they disrupt RustRover's autocomplete functionality.…
Web Developer Travis McCracken on The Case Against Too Many Microservices
via DEV Community: rust (author: Travis McCracken Web Developer)
via DEV Community: rust (author: Travis McCracken Web Developer)
Telegraph
Web Developer Travis McCracken on The Case Against Too Many …
Harnessing the Power of Rust and Go for Backend Development: Insights from Web Developer Travis McCracken As a passionate Web Developer, I’ve always believed that choosing the right tools for backend development can make or break the scalability, performance…
Building a self-hosted, AI-native workflow engine in Rust (180 node types, no SDK bloat)
via DEV Community: rust (author: 元方)
via DEV Community: rust (author: 元方)
Telegraph
Building a self-hosted, AI-native workflow engine in Rust (1…
I've spent the last while building Trigix — an open-source (MIT), self-hostable workflow automation platform. Think n8n, but the execution engine is in Rust and the AI nodes can run entirely against local models. This post is about a few engineering decisions…
I built a safety-first AI IDE in Tauri/Rust – local, free, $0 (7 months solo)
via DEV Community: rust (author: Amritanshu Amar)
via DEV Community: rust (author: Amritanshu Amar)
Telegraph
I built a safety-first AI IDE in Tauri/Rust – local, free, $…
Yesterday, Cursor was acquired by SpaceX for $60 billion. I've been building a free, local-first AI IDE for 7 months. Alone.No VC money. No team. No MIT network. This is that story. Why I built PunamIDE Most AI IDEs are built around one idea: code faster.…
The Bug Behind the Bug: Anatomy of a Three-Layer Consensus Halt
via DEV Community: rust (author: NOVAInetwork)
via DEV Community: rust (author: NOVAInetwork)
Telegraph
The Bug Behind the Bug: Anatomy of a Three-Layer Consensus H…
A dev-log from building an AI-native layer one, mostly alone. I am 18, I build NOVAI, and you can find me as 0x-devc. NOVAI is a layer-one blockchain written from scratch in Rust, with a chained-BFT consensus in the HotStuff family and AI entities as first…
Building a Transparent Drag-and-Drop Shelf for Windows with Tauri: The Engineering War Stories
via DEV Community: rust (author: Zul Ikram Musaddik Rayat)
via DEV Community: rust (author: Zul Ikram Musaddik Rayat)
Telegraph
Building a Transparent Drag-and-Drop Shelf for Windows with …
I recently shipped SnapShelf, a transparent always-on-top "staging shelf" for Windows; you fling files at the right edge of your screen, it slides in, you drop stuff on it, and later you drag that stuff back out into whatever app needs it. Think of it as…