aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteve Moyer <smoyer1@selesy.com>2023-01-18 05:42:25 -0500
committerSteve Moyer <smoyer1@selesy.com>2023-01-18 05:42:25 -0500
commitcf382e0fad77e758898e7d51c4e322645fb6042c (patch)
tree6366928cf572a633cffe5af0de5d97795afe46cf
parent248486708911105e7067cb1061607b712c39a60e (diff)
downloadgit-bug-cf382e0fad77e758898e7d51c4e322645fb6042c.tar.gz
style: clean up linter complaints
-rw-r--r--commands/bug/bug_comment.go2
-rw-r--r--commands/bug/bug_comment_add.go2
-rw-r--r--commands/bug/bug_label.go2
-rw-r--r--commands/bug/bug_select.go2
-rw-r--r--commands/bug/bug_show.go6
-rw-r--r--commands/bug/bug_status.go2
-rw-r--r--commands/bug/bug_status_close.go2
-rw-r--r--commands/bug/bug_status_open.go2
-rw-r--r--commands/bug/bug_title.go2
-rw-r--r--commands/bug/bug_title_edit.go2
10 files changed, 13 insertions, 11 deletions
diff --git a/commands/bug/bug_comment.go b/commands/bug/bug_comment.go
index 5cb8ff17..b037f688 100644
--- a/commands/bug/bug_comment.go
+++ b/commands/bug/bug_comment.go
@@ -26,7 +26,7 @@ func newBugCommentCommand(env *execenv.Env) *cobra.Command {
}
func runBugComment(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_comment_add.go b/commands/bug/bug_comment_add.go
index 152a1893..132de233 100644
--- a/commands/bug/bug_comment_add.go
+++ b/commands/bug/bug_comment_add.go
@@ -41,7 +41,7 @@ func newBugCommentNewCommand(env *execenv.Env) *cobra.Command {
}
func runBugCommentNew(env *execenv.Env, opts bugCommentNewOptions, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_label.go b/commands/bug/bug_label.go
index 554496e3..ec076922 100644
--- a/commands/bug/bug_label.go
+++ b/commands/bug/bug_label.go
@@ -24,7 +24,7 @@ func newBugLabelCommand(env *execenv.Env) *cobra.Command {
}
func runBugLabel(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_select.go b/commands/bug/bug_select.go
index 652c61ea..c93cd7b1 100644
--- a/commands/bug/bug_select.go
+++ b/commands/bug/bug_select.go
@@ -44,7 +44,7 @@ The complementary command is "git bug deselect" performing the opposite operatio
func runBugSelect(env *execenv.Env, args []string) error {
if len(args) == 0 {
- return errors.New("You must provide a bug id")
+ return errors.New("a bug id must be provided")
}
prefix := args[0]
diff --git a/commands/bug/bug_show.go b/commands/bug/bug_show.go
index 9a03c9a3..38eda54a 100644
--- a/commands/bug/bug_show.go
+++ b/commands/bug/bug_show.go
@@ -47,7 +47,7 @@ func newBugShowCommand(env *execenv.Env) *cobra.Command {
}
func runBugShow(env *execenv.Env, opts bugShowOptions, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
@@ -91,7 +91,9 @@ func runBugShow(env *execenv.Env, opts bugShowOptions, args []string) error {
case "title":
env.Out.Printf("%s\n", snap.Title)
default:
- return fmt.Errorf("\nUnsupported field: %s\n", opts.fields)
+ env.Out.Println()
+
+ return fmt.Errorf("unsupported field: %s", opts.fields)
}
return nil
diff --git a/commands/bug/bug_status.go b/commands/bug/bug_status.go
index 59bef3fd..c8542240 100644
--- a/commands/bug/bug_status.go
+++ b/commands/bug/bug_status.go
@@ -24,7 +24,7 @@ func newBugStatusCommand(env *execenv.Env) *cobra.Command {
}
func runBugStatus(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_status_close.go b/commands/bug/bug_status_close.go
index 1d06007b..7a8ae4de 100644
--- a/commands/bug/bug_status_close.go
+++ b/commands/bug/bug_status_close.go
@@ -21,7 +21,7 @@ func newBugStatusCloseCommand(env *execenv.Env) *cobra.Command {
}
func runBugStatusClose(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_status_open.go b/commands/bug/bug_status_open.go
index e99d2db0..0c0c02f0 100644
--- a/commands/bug/bug_status_open.go
+++ b/commands/bug/bug_status_open.go
@@ -21,7 +21,7 @@ func newBugStatusOpenCommand(env *execenv.Env) *cobra.Command {
}
func runBugStatusOpen(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_title.go b/commands/bug/bug_title.go
index 47603410..af959fb7 100644
--- a/commands/bug/bug_title.go
+++ b/commands/bug/bug_title.go
@@ -23,7 +23,7 @@ func newBugTitleCommand(env *execenv.Env) *cobra.Command {
}
func runBugTitle(env *execenv.Env, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}
diff --git a/commands/bug/bug_title_edit.go b/commands/bug/bug_title_edit.go
index fc60824f..2d6bafca 100644
--- a/commands/bug/bug_title_edit.go
+++ b/commands/bug/bug_title_edit.go
@@ -38,7 +38,7 @@ func newBugTitleEditCommand(env *execenv.Env) *cobra.Command {
}
func runBugTitleEdit(env *execenv.Env, opts bugTitleEditOptions, args []string) error {
- b, args, err := ResolveSelected(env.Backend, args)
+ b, _, err := ResolveSelected(env.Backend, args)
if err != nil {
return err
}