(projectName: string)
| 21 | const execFile = promisify(execFileCallback) |
| 22 | |
| 23 | function sanitizeProjectFolderName(projectName: string) { |
| 24 | let nextName = projectName |
| 25 | .trim() |
| 26 | .replaceAll(/[<>:"/\\|?*]/g, '-') |
| 27 | .replace(/\s+/g, ' ') |
| 28 | |
| 29 | nextName = Array.from(nextName, (char) => { |
| 30 | const code = char.charCodeAt(0) |
| 31 | return code >= 0 && code <= 31 ? '-' : char |
| 32 | }).join('') |
| 33 | |
| 34 | return nextName |
| 35 | } |
| 36 | |
| 37 | export async function createProject(options: { |
| 38 | preferredProjectLocation: string | null |
no outgoing calls
no test coverage detected