You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
returnfmt.Errorf("failed to create branch %s: %v, does it already exist? If so, please delete it with `git branch -D %s` first", branchName, err, branchName)
returnfmt.Errorf("failed to create branch %s: %v, does it already exist? If so, please delete it with `git branch -D %s` first", branchName, err, branchName)
225
+
returnfmt.Errorf("failed to checkout master branch: %v", err)
pkoCmd.Flags().StringVarP(&ops.packageTag, "tag", "t", "", "Package tag being promoted to")
31
+
pkoCmd.Flags().StringVarP(&ops.appInterfaceCheckoutDir, "appInterfaceDir", "", "", "location of app-interfache checkout. Falls back to `pwd` and "+git.DefaultAppInterfaceDirectory())
31
32
pkoCmd.Flags().BoolVar(&ops.hcp, "hcp", false, "The service being promoted conforms to the HyperShift progressive delivery definition")
32
33
returnpkoCmd
33
34
}
34
35
35
36
// pkoOptions defines the options provided by this command
saasCmd.Flags().BoolVarP(&ops.hcp, "hcp", "", false, "Git hash of the SaaS service/operator commit getting promoted")
73
+
saasCmd.Flags().StringVarP(&ops.appInterfaceCheckoutDir, "appInterfaceDir", "", "", "location of app-interfache checkout. Falls back to `pwd` and "+git.DefaultAppInterfaceDirectory())
72
74
73
75
returnsaasCmd
74
76
}
75
77
76
78
func (o*saasOptions) validateSaasFlow() {
77
-
ifo.serviceName==""||o.gitHash=="" {
78
-
fmt.Printf("Usage: For SaaS services/operators, please provide --serviceName and --gitHash\n")
79
+
ifo.serviceName==""&&o.gitHash=="" {
80
+
fmt.Printf("Usage: For SaaS services/operators, please provide --serviceName and (optional) --gitHash\n")
79
81
fmt.Printf("--serviceName is the name of the service, i.e. saas-managed-cluster-config\n")
80
82
fmt.Printf("--gitHash is the target git commit in the service, if not specified defaults to HEAD of master\n\n")
commitMessage:=fmt.Sprintf("Promote %s to %s\n\nSee %s/compare/%s...%s for contents of the promotion.", serviceName, promotionGitHash, serviceRepo, currentGitHash, promotionGitHash)
0 commit comments