Creating snippet without a path freezes the cli

The following discussion from !1452 (merged) should be addressed:

  • @jay_mccure started a discussion:

    				if opts.DisplayFilename == "" {
    					return &cmdutils.FlagError{Err: errors.New("if 'path' is not provided, 'filename' is required.")}
                                    } else {
                                            opts.FilePath = opts.DisplayFilename
                                    }

    I've noticed an existing bug here, when we don't pass a path (e.g. glab snippet create -t mysnip --filename foo) it freezes the cli. The fix is above but i will create an issue for this and it can be separate from this MR.

Assignee Loading
Time tracking Loading