do not assume public when creating repo non-interactively
This commit is contained in:
parent
3a492b892a
commit
a811e72c9d
1 changed files with 3 additions and 2 deletions
|
|
@ -75,10 +75,11 @@ func NewCmdCreate(f *cmdutil.Factory, runF func(*CreateOptions) error) *cobra.Co
|
|||
|
||||
if !opts.IO.CanPrompt() {
|
||||
if opts.Name == "" {
|
||||
return &cmdutil.FlagError{Err: errors.New("must pass name argument when not running interactively")}
|
||||
return &cmdutil.FlagError{Err: errors.New("name argument required when not running interactively")}
|
||||
}
|
||||
|
||||
if !opts.Internal && !opts.Private && !opts.Public {
|
||||
opts.Public = true
|
||||
return &cmdutil.FlagError{Err: errors.New("--public, --private, or --internal required when not running interactively")}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue