Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions pkg/commands/compute/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,11 @@ func verifyDirectory(flags config.Flag, dir string, skipVerification bool, out i
return false, err
}

if strings.Contains(dir, " ") && !flags.AutoYes && !flags.NonInteractive {
text.Warning(out, "Your project path contains spaces. In some cases this can result in issues with your installed language toolchain, e.g. `npm`. Consider removing any spaces.")
text.Break(out)
}

if len(files) > 0 && !flags.AutoYes && !flags.NonInteractive {
label := fmt.Sprintf("The current directory isn't empty. Are you sure you want to initialize a Compute@Edge project in %s? [y/N] ", dir)
result, err := text.AskYesNo(out, label, in)
Expand Down