diff --git a/cmd/sharedflows/crtsf.go b/cmd/sharedflows/crtsf.go index 288ab809d..0a60acefe 100644 --- a/cmd/sharedflows/crtsf.go +++ b/cmd/sharedflows/crtsf.go @@ -18,6 +18,7 @@ import ( "fmt" "os" "path" + "path/filepath" "internal/apiclient" @@ -55,6 +56,9 @@ var CreateCmd = &cobra.Command{ if stat, err := os.Stat(folder); err == nil && !stat.IsDir() { return fmt.Errorf("supplied path is not a folder") } + if filepath.Base(sfFolder) != "sharedflowbundle" { + return fmt.Errorf("--sf-folder or -p must be a path to sharedflowbundle folder") + } tmpDir, err := os.MkdirTemp("", "sf") if err != nil { return err