mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-04-20 07:41:22 +02:00
Implements a unified action system that serves as a single source of truth for all operations in Yaak (Tauri app, CLI, plugins, deep links, MCP server). Key features: - ActionExecutor: Combined registry and execution engine with async RwLock - ActionHandler: Trait-based handlers using async closures - Context system: RequiredContext and CurrentContext for action availability - Action groups: Organize related actions - TypeScript bindings: Auto-generated via ts-rs for frontend use Design highlights: - Handlers are closures (no dependencies on other yaak crates) - Registration requires both metadata and handler (prevents orphan actions) - Flexible return values via serde_json::Value - All methods are async using tokio All 33 tests passing. Ready for integration with yaak-core and yaak-app. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
16 lines
423 B
TOML
16 lines
423 B
TOML
[package]
|
|
name = "yaak-actions"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
description = "Centralized action system for Yaak"
|
|
|
|
[dependencies]
|
|
serde = { workspace = true, features = ["derive"] }
|
|
serde_json = { workspace = true }
|
|
thiserror = { workspace = true }
|
|
tokio = { workspace = true, features = ["sync"] }
|
|
ts-rs = { workspace = true }
|
|
|
|
[dev-dependencies]
|
|
tokio = { workspace = true, features = ["rt-multi-thread", "macros"] }
|