mirror of
https://github.com/storytold/designcraft.git
synced 2026-11-14 14:22:39 +00:00
Fix MCP temporary directory build on Windows
This commit is contained in:
1 parent
0e85e9e5ec
commit
f238a9a51e
1 file changed
+3
@@ -565,7 +565,10 @@ fn screenshot(b: &mut dyn Backend, a: &Args) -> Result<ToolResult, String> {
|
||||
fn private_temp_dir(prefix: &str) -> Result<std::path::PathBuf, String> {
|
||||
let nanos = std::time::SystemTime::UNIX_EPOCH.elapsed().map_or(0, |d| d.as_nanos());
|
||||
let dir = std::env::temp_dir().join(format!("{prefix}-{}-{nanos}", std::process::id()));
|
||||
#[cfg(unix)]
|
||||
let mut builder = std::fs::DirBuilder::new();
|
||||
#[cfg(not(unix))]
|
||||
let builder = std::fs::DirBuilder::new();
|
||||
#[cfg(unix)]
|
||||
{
|
||||
use std::os::unix::fs::DirBuilderExt;
|
||||
|
||||
Reference in new issue
Block a user