Skip to content
This repository has been archived by the owner on Nov 22, 2022. It is now read-only.

style: formalize message telling issue/mr was closed/reopened #462

Merged
merged 5 commits into from
Dec 31, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion commands/issue/close/issue_close.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ func NewCmdClose(f *cmdutils.Factory) *cobra.Command {
if err != nil {
return err
}
fmt.Fprintln(f.IO.StdOut, utils.GreenCheck()+" Issue #"+i2+" closed\n")
fmt.Fprintf(f.IO.StdOut, "%s Closed Issue #%s\n", utils.RedCheck(), i2)
fmt.Fprintln(f.IO.StdOut, issueutils.DisplayIssue(issue))
}
return nil
Expand Down
2 changes: 1 addition & 1 deletion commands/issue/close/issue_close_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func Test_issueClose(t *testing.T) {
{
Name: "Issue Exists",
Issue: "1",
ExpectedMsg: []string{"Closing Issue...", "Issue #1 closed"},
ExpectedMsg: []string{"Closing Issue...", "Closed Issue #1"},
},
{
Name: "Issue Does Not Exist",
Expand Down
2 changes: 1 addition & 1 deletion commands/issue/reopen/issue_reopen.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func NewCmdReopen(f *cmdutils.Factory) *cobra.Command {
return err
}

fmt.Fprintln(out, utils.GreenCheck(), "Issue #"+i2+" reopened")
fmt.Fprintf(out, "%s Reopened Issue #%s\n", utils.GreenCheck(), i2)
fmt.Fprintln(out, issueutils.DisplayIssue(issue))
}
return nil
Expand Down
2 changes: 1 addition & 1 deletion commands/mr/close/mr_close.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func NewCmdClose(f *cmdutils.Factory) *cobra.Command {
if err != nil {
return err
}
fmt.Fprintf(f.IO.StdOut, "%s Merge request !%d\n", utils.RedCheck(), mr.IID)
fmt.Fprintf(f.IO.StdOut, "%s Closed Merge request !%d\n", utils.RedCheck(), mr.IID)
fmt.Fprintln(f.IO.StdOut, mrutils.DisplayMR(mr))
}

Expand Down
2 changes: 1 addition & 1 deletion commands/mr/reopen/mr_reopen.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func NewCmdReopen(f *cmdutils.Factory) *cobra.Command {
return err
}

fmt.Fprintf(f.IO.StdOut, "%s Merge request !%d reopened\n", utils.GreenCheck(), mr.IID)
fmt.Fprintf(f.IO.StdOut, "%s Reopened Merge request !%d\n", utils.GreenCheck(), mr.IID)
fmt.Fprintln(f.IO.StdOut, mrutils.DisplayMR(mr))
}

Expand Down