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
@@ -220,20 +222,14 @@ func (o *StartBuildOptions) Complete(f *clientcmd.Factory, in io.Reader, out, er
220
222
returnkcmdutil.UsageErrorf(cmd, "The '--from-webhook' flag is incompatible with arguments and all '--from-*' flags")
221
223
}
222
224
if!strings.HasSuffix(webhook, "/generic") {
223
-
fmt.Fprintf(errout, "warning: the '--from-webhook' flag should be called with a generic webhook URL.\n")
225
+
fmt.Fprintf(o.ErrOut, "warning: the '--from-webhook' flag should be called with a generic webhook URL.\n")
224
226
}
225
227
returnnil
226
228
227
229
caselen(args) !=1&&len(buildName) ==0:
228
230
returnkcmdutil.UsageErrorf(cmd, "Must pass a name of a build config or specify build name with '--from-build' flag.\nUse \"%s get bc\" to list all available build configs.", cmdFullName)
229
231
}
230
232
231
-
iflen(buildName) !=0&&o.AsBinary {
232
-
// TODO: we should support this, it should be possible to clone a build to run again with new uploaded artifacts.
233
-
// Doing so requires introducing a new clonebinary endpoint.
234
-
returnkcmdutil.UsageErrorf(cmd, "Cannot use '--from-build' flag with binary builds")
235
-
}
236
-
237
233
namespace, _, err:=f.DefaultNamespace()
238
234
iferr!=nil {
239
235
returnerr
@@ -288,16 +284,12 @@ func (o *StartBuildOptions) Complete(f *clientcmd.Factory, in io.Reader, out, er
288
284
name=ref.Name
289
285
}
290
286
291
-
iflen(name) ==0 {
292
-
returnfmt.Errorf("a resource name is required either as an argument or by using --from-build")
0 commit comments