diff options
Diffstat (limited to 'crates/fidget-spinner-cli/src/mcp/host/config.rs')
| -rw-r--r-- | crates/fidget-spinner-cli/src/mcp/host/config.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/crates/fidget-spinner-cli/src/mcp/host/config.rs b/crates/fidget-spinner-cli/src/mcp/host/config.rs new file mode 100644 index 0000000..8d1ee4b --- /dev/null +++ b/crates/fidget-spinner-cli/src/mcp/host/config.rs @@ -0,0 +1,18 @@ +use std::path::PathBuf; + +use fidget_spinner_store_sqlite::StoreError; + +#[derive(Clone, Debug)] +pub(super) struct HostConfig { + pub(super) executable: PathBuf, + pub(super) initial_project: Option<PathBuf>, +} + +impl HostConfig { + pub(super) fn new(initial_project: Option<PathBuf>) -> Result<Self, StoreError> { + Ok(Self { + executable: std::env::current_exe()?, + initial_project, + }) + } +} |