Load default file and stop overwriting main.kcl

This commit is contained in:
49lf
2024-07-31 11:51:56 -04:00
parent 4cc06e0efc
commit 4afbb1eae7

View File

@ -234,12 +234,17 @@ const getDefaultKclFileForDir = async (projectDir, file) => {
return getDefaultKclFileForDir(entry.path, entry)
}
}
// If we didn't find a kcl file, create one.
await window.electron.writeFile(defaultFilePath, '')
return defaultFilePath
}
}
}
// If we didn't find a kcl file, create one.
await window.electron.writeFile(defaultFilePath, '')
if (!file.children) {
return file.name
}
return defaultFilePath
}