Architecture
Application Architecture
How the React frontend, Zustand store, Tauri commands, Rust services, SQLite, Keychain, and CLI fit together.
Frontend
- React app mounted from src/main.tsx.
- App route selection comes from a single Zustand project store.
- Feature folders contain route UI for dashboard, projects, variables, compare, security, settings, about, env files, and profiles.
- Pure utility modules in src/lib handle parser, validators, backups, persistence serialization, sync, history, clipboard, theme, schema, runtime scripts, and profile import.
State boundary
The Zustand project store owns project selection, active env file, active route, filters, search, reveal state, previews, pending exports, settings, App Lock status, imports, persistence hydration, profile CRUD, variable actions, backups, connector config, and audit writes.
Tauri backend
- Project commands scan folders and open project paths.
- Env-file commands parse files.
- Export commands generate examples, write env files, write text files, read text files, and test path existence.
- Keychain commands save, reveal, and delete secret values.
- CLI commands install, repair, uninstall, inspect, and run doctor for the local envvault command.
- Connector config commands write and read .envvault.json.
- Security commands inspect .gitignore coverage.
- Auth commands get App Lock status, set up passphrase protection, unlock, lock, toggle macOS authentication, and disable App Lock.
Runtime CLI
The bundled CLI runtime supports doctor, profiles, print, validate, and run. It reads SQLite metadata, resolves Keychain-backed secrets, validates profile variables, and injects environment variables into a child process.