vibe-action 0.2.0

Command router — execute shell commands and LLM prompts via simple YAML actions.
//! System provider for `{system_shell}` — current shell from SHELL env.

use crate::models::context::ContextModel;
use crate::system::system::SystemKey;
use crate::system::system::SystemProvider;
use anyhow::Result;

pub struct SystemShellProvider;

impl SystemProvider for SystemShellProvider {
    fn key(&self) -> SystemKey {
        SystemKey::Shell
    }

    fn resolve(&self) -> Result<ContextModel> {
        let shell = std::env::var("SHELL")
            .unwrap_or_default()
            .split('/')
            .last()
            .unwrap_or("unknown")
            .to_string();
        Ok(ContextModel::String(shell))
    }
}