mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-03-23 23:59:24 +08:00
Implement OpenCode-specific provider service logic with additive mode: - add(): Always write to live config (no is_current check needed) - update(): Always sync changes to live config - delete(): Remove from both DB and live config (no is_current check) New helper functions in live.rs: - write_live_snapshot(): Write provider to opencode.json provider section - remove_opencode_provider_from_live(): Remove provider from live config - import_opencode_providers_from_live(): Import existing providers from ~/.config/opencode/opencode.json into CC Switch database Key design: OpenCode uses additive mode where all providers coexist in the config file, unlike Claude/Codex/Gemini which use replacement mode with a single active provider.