This project includes two convenience scripts for building and installing Sorcery Desktop on macOS:
Creates a complete app bundle and installs it to /Applications.
Use this when:
- First time setup
- You've changed UI files, icons, or other resources
- You need a complete rebuild
What it does:
- Builds the Rust binary (
cargo build) - Creates the macOS app bundle (
cargo tauri build --debug) - Stops any running instances
- Copies the bundle to
/Applications/Sorcery Desktop.app - Registers the
srcuri://protocol handler
Time: ~10-20 seconds (depending on changes)
Updates only the binary inside the existing app bundle.
Use this when:
- You've only changed Rust code
- You want fast iteration during development
- The app bundle already exists in
/Applications
What it does:
- Builds the Rust binary (
cargo build) - Stops any running instances
- Replaces the binary in
/Applications/Sorcery Desktop.app/Contents/MacOS/ - Re-registers the protocol handler
Time: ~2-5 seconds
Note: This requires that you've run ./install-local.sh at least once to create the app bundle.
# First time setup or after resource changes
./install-local.sh
# Quick iteration during development
./install-dev.sh
# Typical workflow
./install-dev.sh # After code changes
./install-dev.sh # After more code changes
./install-local.sh # After changing icons/UI
./install-dev.sh # Back to quick iterationsBoth scripts automatically register the srcuri:// protocol handler with macOS. The registration runs in the background and may take a few seconds to complete.
To verify registration:
# Check if protocol is registered
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -dump | grep -i srcuri
# Test a protocol link
open "srcuri://myproject/README.md@L10"The app uses single-instance mode - only one copy can run at a time:
- Launching a second instance will activate the first one
- Deep links passed to the second instance are forwarded to the first
- The second instance then exits automatically
App won't open after install:
# Check if it's running
ps aux | grep sorcery
# Kill any stuck instances
pkill -f sorcery
# Try installing again
./install-dev.shProtocol handler not working:
# Force re-registration (foreground, to see errors)
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -f "/Applications/Sorcery Desktop.app"
# Restart Finder/Dock (sometimes needed)
killall Finder
killall DockBuild errors:
# Clean build
cd src-tauri
cargo clean
cargo build
# Then install
cd ..
./install-local.shWarning about bundle identifier: You may see this warning during builds:
Warn The bundle identifier "com.srcuri.app" set in `tauri.conf.json identifier` ends with `.app`
This is safe to ignore - it's just a warning about naming conventions.