X Tutup
Skip to content

Commit f46bab2

Browse files
committed
Rename to SuccessIconWithColor
1 parent 96fa6e7 commit f46bab2

File tree

14 files changed

+17
-17
lines changed

14 files changed

+17
-17
lines changed

pkg/cmd/alias/delete/delete.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ func deleteRun(opts *DeleteOptions) error {
6363

6464
if opts.IO.IsStdoutTTY() {
6565
cs := opts.IO.ColorScheme()
66-
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted alias %s; was %s\n", cs.SuccessIconOfColor(cs.Red), opts.Name, expansion)
66+
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted alias %s; was %s\n", cs.SuccessIconWithColor(cs.Red), opts.Name, expansion)
6767
}
6868

6969
return nil

pkg/cmd/gist/create/create.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ func createRun(opts *CreateOptions) error {
140140
return fmt.Errorf("%s Failed to create gist: %w", cs.Red("X"), err)
141141
}
142142

143-
fmt.Fprintf(errOut, "%s %s\n", cs.SuccessIconOfColor(cs.Green), completionMessage)
143+
fmt.Fprintf(errOut, "%s %s\n", cs.SuccessIconWithColor(cs.Green), completionMessage)
144144

145145
if opts.WebMode {
146146
fmt.Fprintf(opts.IO.Out, "Opening %s in your browser.\n", utils.DisplayURL(gist.HTMLURL))

pkg/cmd/issue/close/close.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ func closeRun(opts *CloseOptions) error {
7575
return err
7676
}
7777

78-
fmt.Fprintf(opts.IO.ErrOut, "%s Closed issue #%d (%s)\n", cs.SuccessIconOfColor(cs.Red), issue.Number, issue.Title)
78+
fmt.Fprintf(opts.IO.ErrOut, "%s Closed issue #%d (%s)\n", cs.SuccessIconWithColor(cs.Red), issue.Number, issue.Title)
7979

8080
return nil
8181
}

pkg/cmd/issue/reopen/reopen.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ func reopenRun(opts *ReopenOptions) error {
7575
return err
7676
}
7777

78-
fmt.Fprintf(opts.IO.ErrOut, "%s Reopened issue #%d (%s)\n", cs.SuccessIconOfColor(cs.Green), issue.Number, issue.Title)
78+
fmt.Fprintf(opts.IO.ErrOut, "%s Reopened issue #%d (%s)\n", cs.SuccessIconWithColor(cs.Green), issue.Number, issue.Title)
7979

8080
return nil
8181
}

pkg/cmd/pr/close/close.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ func closeRun(opts *CloseOptions) error {
8686
return fmt.Errorf("API call failed: %w", err)
8787
}
8888

89-
fmt.Fprintf(opts.IO.ErrOut, "%s Closed pull request #%d (%s)\n", cs.SuccessIconOfColor(cs.Red), pr.Number, pr.Title)
89+
fmt.Fprintf(opts.IO.ErrOut, "%s Closed pull request #%d (%s)\n", cs.SuccessIconWithColor(cs.Red), pr.Number, pr.Title)
9090

9191
crossRepoPR := pr.HeadRepositoryOwner.Login != baseRepo.RepoOwner()
9292

@@ -132,7 +132,7 @@ func closeRun(opts *CloseOptions) error {
132132
return err
133133
}
134134
}
135-
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted branch %s%s\n", cs.SuccessIconOfColor(cs.Red), cs.Cyan(pr.HeadRefName), branchSwitchString)
135+
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted branch %s%s\n", cs.SuccessIconWithColor(cs.Red), cs.Cyan(pr.HeadRefName), branchSwitchString)
136136
}
137137

138138
return nil

pkg/cmd/pr/merge/merge.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ func mergeRun(opts *MergeOptions) error {
180180
case api.PullRequestMergeMethodSquash:
181181
action = "Squashed and merged"
182182
}
183-
fmt.Fprintf(opts.IO.ErrOut, "%s %s pull request #%d (%s)\n", cs.SuccessIconOfColor(cs.Magenta), action, pr.Number, pr.Title)
183+
fmt.Fprintf(opts.IO.ErrOut, "%s %s pull request #%d (%s)\n", cs.SuccessIconWithColor(cs.Magenta), action, pr.Number, pr.Title)
184184
}
185185
} else if !opts.IsDeleteBranchIndicated && opts.InteractiveMode && !crossRepoPR {
186186
err := prompt.SurveyAskOne(&survey.Confirm{
@@ -243,7 +243,7 @@ func mergeRun(opts *MergeOptions) error {
243243
}
244244

245245
if isTerminal {
246-
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted branch %s%s\n", cs.SuccessIconOfColor(cs.Red), cs.Cyan(pr.HeadRefName), branchSwitchString)
246+
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted branch %s%s\n", cs.SuccessIconWithColor(cs.Red), cs.Cyan(pr.HeadRefName), branchSwitchString)
247247
}
248248

249249
return nil

pkg/cmd/pr/ready/ready.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ func readyRun(opts *ReadyOptions) error {
8888
return fmt.Errorf("API call failed: %w", err)
8989
}
9090

91-
fmt.Fprintf(opts.IO.ErrOut, "%s Pull request #%d is marked as \"ready for review\"\n", cs.SuccessIconOfColor(cs.Green), pr.Number)
91+
fmt.Fprintf(opts.IO.ErrOut, "%s Pull request #%d is marked as \"ready for review\"\n", cs.SuccessIconWithColor(cs.Green), pr.Number)
9292

9393
return nil
9494
}

pkg/cmd/pr/reopen/reopen.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ func reopenRun(opts *ReopenOptions) error {
8080
return fmt.Errorf("API call failed: %w", err)
8181
}
8282

83-
fmt.Fprintf(opts.IO.ErrOut, "%s Reopened pull request #%d (%s)\n", cs.SuccessIconOfColor(cs.Green), pr.Number, pr.Title)
83+
fmt.Fprintf(opts.IO.ErrOut, "%s Reopened pull request #%d (%s)\n", cs.SuccessIconWithColor(cs.Green), pr.Number, pr.Title)
8484

8585
return nil
8686
}

pkg/cmd/release/delete/delete.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ func deleteRun(opts *DeleteOptions) error {
9292
}
9393

9494
iofmt := opts.IO.ColorScheme()
95-
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted release %s\n", iofmt.SuccessIconOfColor(iofmt.Red), release.TagName)
95+
fmt.Fprintf(opts.IO.ErrOut, "%s Deleted release %s\n", iofmt.SuccessIconWithColor(iofmt.Red), release.TagName)
9696
if !release.IsDraft {
9797
fmt.Fprintf(opts.IO.ErrOut, "%s Note that the %s git tag still remains in the repository\n", iofmt.WarningIcon(), release.TagName)
9898
}

pkg/cmd/repo/create/create.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ func createRun(opts *CreateOptions) error {
249249
isTTY := opts.IO.IsStdoutTTY()
250250

251251
if isTTY {
252-
fmt.Fprintf(stderr, "%s Created repository %s on GitHub\n", cs.SuccessIconOfColor(cs.Green), ghrepo.FullName(repo))
252+
fmt.Fprintf(stderr, "%s Created repository %s on GitHub\n", cs.SuccessIconWithColor(cs.Green), ghrepo.FullName(repo))
253253
} else {
254254
fmt.Fprintln(stdout, repo.URL)
255255
}

0 commit comments

Comments
 (0)
X Tutup