Skip to content
This repository was archived by the owner on Jan 4, 2025. It is now read-only.

Commit 7bc022f

Browse files
💀 Fix bug that gowl edit can't open a specified repository
1 parent 8a43b16 commit 7bc022f

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

args.go

+15-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,21 @@ type Args struct {
4242
BitbucketServer bool `docopt:"--bitbucket-server"`
4343
}
4444

45-
// CreateArgs creates Args
45+
/*
46+
CreateArgs creates Args.
47+
48+
Example:
49+
50+
args, appEnd, err := CreateArgs(usage, os.Args[1:], version)
51+
if err != nil {
52+
log.Fatal(errors.Wrap(err, "Fail to create arguments."))
53+
}
54+
if appEnd {
55+
return
56+
}
57+
58+
fmt.Println(args)
59+
*/
4660
func CreateArgs(usage string, argv []string, version string) (Args, bool, error) {
4761
parser := &docopt.Parser{
4862
HelpHandler: docopt.PrintHelpOnly,

command.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ func CmdEdit(handler IHandler, root string, subSpaces []string, editor string) e
234234
return errors.Wrap(err, "Fail to select a repository.")
235235
}
236236

237-
if err := execCommand(&selection, editor); err != nil {
237+
if err := execCommand(&selection, editor, "."); err != nil {
238238
return errors.Wrap(err, fmt.Sprintf("Fail to edit repository %v", selection))
239239
}
240240

0 commit comments

Comments
 (0)