nebius/SWE-rebench-V2-PRs huggingface dataset:
Repository: cli/cli
Pull request #8837 (2024-03-18 14:01:48)

Fixed `gh pr lock/unlock` not working when URL is passed
<!--
  Thank you for contributing to GitHub CLI!
  To reference an open issue, please write this in your description: `Fixes #NUMBER`
-->
Fixes https://github.com/cli/cli/issues/8816

HI all, I have fixed this PR to not work with `gh pr lock/unlock` commands when a URL is passed to them.
The regular expression that determines URLs has been changed so that PR URLs can also be matched.
Also, tests that may be relevant have been added.


Patch:
diff --git a/pkg/cmd/issue/shared/lookup.go b/pkg/cmd/issue/shared/lookup.go
index 1aa58c951..f93b0867d 100644
--- a/pkg/cmd/issue/shared/lookup.go
+++ b/pkg/cmd/issue/shared/lookup.go
@@ -100,7 +100,7 @@ func IssuesFromArgsWithFields(httpClient *http.Client, baseRepoFn func() (ghrepo
 	return issues, issuesRepo, nil
 }
 
-var issueURLRE = regexp.MustCompile(`^/([^/]+)/([^/]+)/issues/(\d+)`)
+var issueURLRE = regexp.MustCompile(`^/([^/]+)/([^/]+)/(?:issues|pull)/(\d+)`)
 
 func issueMetadataFromURL(s string) (int, ghrepo.Interface) {
 	u, err := url.Parse(s)


Test patch:
diff --git a/pkg/cmd/issue/shared/lookup_test.go b/pkg/cmd/issue/shared/lookup_test.go
index 694a3fd05..44f496de4 100644
--- a/pkg/cmd/issue/shared/lookup_test.go
+++ b/pkg/cmd/issue/shared/lookup_test.go
@@ -79,6 +79,23 @@ func TestIssueFromArgWithFields(t *testing.T) {
 			wantIssue: 13,
 			wantRepo:  "https://example.org/OWNER/REPO",
 		},
+		{
+			name: "PR URL argument",
+			args: args{
+				selector:   "https://example.org/OWNER/REPO/pull/13#comment-123",
+				baseRepoFn: nil,
+			},
+			httpStub: func(r *httpmock.Registry) {
+				r.Register(
+					httpmock.GraphQL(`query IssueByNumber\b`),
+					httpmock.StringResponse(`{"data":{"repository":{
+						"hasIssuesEnabled": true,
+						"issue":{"number":13}
+					}}}`))
+			},
+			wantIssue: 13,
+			wantRepo:  "https://example.org/OWNER/REPO",
+		},
 		{
 			name: "project cards permission issue",
 			args: args{
Repository: cli/cli
Pull request #9004 (2024-04-26 10:30:14)

Add colon for `gh secret set`
<!--
  Thank you for contributing to GitHub CLI!
  To reference an open issue, please write this in your description: `Fixes #NUMBER`
-->

I understand that opening a PR directly violates the contribution guidelines, and I'm sorry for that, but I think this is an issue that can be fixed quickly.

I think the [paste secret prompt](https://github.com/cli/cli/blob/28c4d3075b5916acdb6974a7e4f5c49d2c274a86/pkg/cmd/secret/set/set.go#L382) in GitHub Cli is missing a colon, which is inconsistent with other [existing prompts](https://github.com/cli/cli/blob/28c4d3075b5916acdb6974a7e4f5c49d2c274a86/internal/prompter/prompter.go#L70) and creates ambiguity

Before change:

``` shell
? Paste your secret
```

(The missing colon may be interpreted as automatically pasting from the clipboard rather than typing after prompting)

After changes:

``` shell
? Paste your secret:
```

cliAutomation: Hi! Thanks for the pull request. Please ensure that this change is linked to an issue by mentioning an issue number in the description of the pull request. If this pull request would close the issue, please put the word 'Fixes' before the issue number somewhere in the pull request body. If this is a tiny change like fixing a typo, feel free to ignore this message.

Patch:
diff --git a/pkg/cmd/auth/shared/login_flow.go b/pkg/cmd/auth/shared/login_flow.go
index 4a5e45326..5a1df34c6 100644
--- a/pkg/cmd/auth/shared/login_flow.go
+++ b/pkg/cmd/auth/shared/login_flow.go
@@ -111,7 +111,7 @@ func Login(opts *LoginOptions) error {
 
 			if sshChoice {
 				passphrase, err := opts.Prompter.Password(
-					"Enter a passphrase for your new SSH key (Optional)")
+					"Enter a passphrase for your new SSH key (Optional):")
 				if err != nil {
 					return err
 				}
diff --git a/pkg/cmd/secret/set/set.go b/pkg/cmd/secret/set/set.go
index d5fbede0b..dcfd4df14 100644
--- a/pkg/cmd/secret/set/set.go
+++ b/pkg/cmd/secret/set/set.go
@@ -379,7 +379,7 @@ func getBody(opts *SetOptions) ([]byte, error) {
 	}
 
 	if opts.IO.CanPrompt() {
-		bodyInput, err := opts.Prompter.Password("Paste your secret")
+		bodyInput, err := opts.Prompter.Password("Paste your secret:")
 		if err != nil {
 			return nil, err
 		}


Test patch:
diff --git a/pkg/cmd/secret/set/set_test.go b/pkg/cmd/secret/set/set_test.go
index 376ef2d53..3b46e63f1 100644
--- a/pkg/cmd/secret/set/set_test.go
+++ b/pkg/cmd/secret/set/set_test.go
@@ -596,7 +596,7 @@ func Test_getBodyPrompt(t *testing.T) {
 	ios.SetStdoutTTY(true)
 
 	pm := prompter.NewMockPrompter(t)
-	pm.RegisterPassword("Paste your secret", func(_ string) (string, error) {
+	pm.RegisterPassword("Paste your secret:", func(_ string) (string, error) {
 		return "cool secret", nil
 	})
Repository: cli/cli
Pull request #9033 (2024-05-01 09:58:11)

Do not mutate headers when initialising tableprinter
## Description

This was just really surprising behaviour when I was spiking on some other work, expecting to use use contents of the same slice for the headers and as a lookup key into another `map`. What was happening was that I was providing the slice, the headers were being mutated to uppercase in place, and then the `map` lookup was failing because the key had changed.

I could see an argument that the table "owns" the headers after they are provided but It seems low cost to take a copy to avoid surprising behaviours.


Patch:
diff --git a/internal/tableprinter/table_printer.go b/internal/tableprinter/table_printer.go
index ee1cc07a5..e1454170f 100644
--- a/internal/tableprinter/table_printer.go
+++ b/internal/tableprinter/table_printer.go
@@ -63,9 +63,10 @@ func NewWithWriter(w io.Writer, isTTY bool, maxWidth int, cs *iostreams.ColorSch
 	}
 
 	if isTTY && len(headers.columns) > 0 {
-		// Make sure all headers are uppercase.
+		// Make sure all headers are uppercase, taking a copy of the headers to avoid modifying the original slice.
+		upperCasedHeaders := make([]string, len(headers.columns))
 		for i := range headers.columns {
-			headers.columns[i] = strings.ToUpper(headers.columns[i])
+			upperCasedHeaders[i] = strings.ToUpper(headers.columns[i])
 		}
 
 		// Make sure all header columns are padded - even the last one. Previously, the last header column
@@ -77,7 +78,7 @@ func NewWithWriter(w io.Writer, isTTY bool, maxWidth int, cs *iostreams.ColorSch
 		}
 
 		tp.AddHeader(
-			headers.columns,
+			upperCasedHeaders,
 			WithPadding(paddingFunc),
 			WithColor(cs.LightGrayUnderline),
 		)


Test patch:
diff --git a/internal/tableprinter/table_printer_test.go b/internal/tableprinter/table_printer_test.go
new file mode 100644
index 000000000..840c46456
--- /dev/null
+++ b/internal/tableprinter/table_printer_test.go
@@ -0,0 +1,22 @@
+package tableprinter_test
+
+import (
+	"testing"
+
+	"github.com/cli/cli/v2/internal/tableprinter"
+	"github.com/cli/cli/v2/pkg/iostreams"
+	"github.com/stretchr/testify/require"
+)
+
+func TestHeadersAreNotMutated(t *testing.T) {
+	// Given a TTY environment so that headers are included in the table
+	ios, _, _, _ := iostreams.Test()
+	ios.SetStdoutTTY(true)
+
+	// When creating a new table printer
+	headers := []string{"one", "two", "three"}
+	_ = tableprinter.New(ios, tableprinter.WithHeader(headers...))
+
+	// The provided headers should not be mutated
+	require.Equal(t, []string{"one", "two", "three"}, headers)
+}
Repository: cli/cli
Pull request #9355 (2024-07-23 11:28:40)

Expose fullDatabaseId for PR json export
## Description

Fixes https://github.com/cli/cli/issues/9241

### Acceptance Criteria

**Given** there is a PR that exists with <number> in <repo>
**When** I run `gh pr view --repo <repo> --json number,fullDatabaseId <number>`
**Then** I see a JSON document containing the database ID of the PR as a string

```
➜  ./bin/gh pr list --repo cli/cli | cat
9354    Clarify usage of template flags for PR and issue creation       9220-getting-template-not-found-errors-for-gh-pr-create-template=       OPEN    2024-07-23T11:15:18Z
...
```

```
➜ ./bin/gh pr view --repo cli/cli --json number,fullDatabaseId 9354 | cat
{"fullDatabaseId":"1983091470","number":9354}
```


Patch:
diff --git a/api/queries_pr.go b/api/queries_pr.go
index 0ef089bb5..370f2db24 100644
--- a/api/queries_pr.go
+++ b/api/queries_pr.go
@@ -26,6 +26,7 @@ const (
 
 type PullRequest struct {
 	ID                  string
+	FullDatabaseID      string
 	Number              int
 	Title               string
 	State               string
diff --git a/api/query_builder.go b/api/query_builder.go
index 0aa89513d..30dbeb869 100644
--- a/api/query_builder.go
+++ b/api/query_builder.go
@@ -289,6 +289,7 @@ var PullRequestFields = append(sharedIssuePRFields,
 	"commits",
 	"deletions",
 	"files",
+	"fullDatabaseId",
 	"headRefName",
 	"headRefOid",
 	"headRepository",


Test patch:
diff --git a/pkg/cmd/pr/view/view_test.go b/pkg/cmd/pr/view/view_test.go
index 0efe667a7..2b99df931 100644
--- a/pkg/cmd/pr/view/view_test.go
+++ b/pkg/cmd/pr/view/view_test.go
@@ -41,6 +41,7 @@ func TestJSONFields(t *testing.T) {
 		"createdAt",
 		"deletions",
 		"files",
+		"fullDatabaseId",
 		"headRefName",
 		"headRefOid",
 		"headRepository",
Repository: cli/cli
Pull request #9356 (2024-07-23 11:38:58)

Expose json databaseId field for release commands
## Description

Fixes https://github.com/cli/cli/issues/9278

### Acceptance Criteria

**Given** there is a release with <tag> on <repo>
**When** I run `gh release view --repo <repo> --json name,databaseId <tag>`
**Then** I see a JSON document containing an integer database Id for the release

```
➜ ./bin/gh release list --repo cli/cli | cat
GitHub CLI 2.53.0        Latest  v2.53.0 2024-07-17T18:51:32Z
...
```

```
➜ ./bin/gh release view --repo cli/cli --json name,databaseId v2.53.0 | cat
{"databaseId":165912183,"name":"GitHub CLI 2.53.0"}
```


Patch:
diff --git a/pkg/cmd/release/shared/fetch.go b/pkg/cmd/release/shared/fetch.go
index 84a9a369b..c9cf7a6a4 100644
--- a/pkg/cmd/release/shared/fetch.go
+++ b/pkg/cmd/release/shared/fetch.go
@@ -21,22 +21,23 @@ import (
 )
 
 var ReleaseFields = []string{
-	"url",
 	"apiUrl",
-	"uploadUrl",
-	"tarballUrl",
-	"zipballUrl",
-	"id",
-	"tagName",
-	"name",
+	"author",
+	"assets",
 	"body",
+	"createdAt",
+	"databaseId",
+	"id",
 	"isDraft",
 	"isPrerelease",
-	"createdAt",
+	"name",
 	"publishedAt",
+	"tagName",
+	"tarballUrl",
 	"targetCommitish",
-	"author",
-	"assets",
+	"uploadUrl",
+	"url",
+	"zipballUrl",
 }
 
 type Release struct {


Test patch:
diff --git a/pkg/cmd/release/view/view_test.go b/pkg/cmd/release/view/view_test.go
index c8b837923..629c0728d 100644
--- a/pkg/cmd/release/view/view_test.go
+++ b/pkg/cmd/release/view/view_test.go
@@ -14,11 +14,34 @@ import (
 	"github.com/cli/cli/v2/pkg/cmdutil"
 	"github.com/cli/cli/v2/pkg/httpmock"
 	"github.com/cli/cli/v2/pkg/iostreams"
+	"github.com/cli/cli/v2/pkg/jsonfieldstest"
 	"github.com/google/shlex"
 	"github.com/stretchr/testify/assert"
 	"github.com/stretchr/testify/require"
 )
 
+func TestJSONFields(t *testing.T) {
+	jsonfieldstest.ExpectCommandToSupportJSONFields(t, NewCmdView, []string{
+		"apiUrl",
+		"author",
+		"assets",
+		"body",
+		"createdAt",
+		"databaseId",
+		"id",
+		"isDraft",
+		"isPrerelease",
+		"name",
+		"publishedAt",
+		"tagName",
+		"tarballUrl",
+		"targetCommitish",
+		"uploadUrl",
+		"url",
+		"zipballUrl",
+	})
+}
+
 func Test_NewCmdView(t *testing.T) {
 	tests := []struct {
 		name    string
Repository: cli/cli
Pull request #9650 (2024-09-21 20:13:58)

Emit a log message when extension installation falls back to a `darwin-amd64` binary on an Apple Silicon macOS device
I've made a bunch of changes recently to improve the experience of installing CLI extensions on an Apple Silicon macOS device (`darwin-arm64`).

This makes one last improvement: logging a transparent message when we fall back to installing an available `darwin-amd64` binary.

_Please forgive me for not creating an issue first 🙏🏻_ 


Patch:
diff --git a/pkg/cmd/extension/manager.go b/pkg/cmd/extension/manager.go
index 410d4c224..2431c6b83 100644
--- a/pkg/cmd/extension/manager.go
+++ b/pkg/cmd/extension/manager.go
@@ -29,6 +29,8 @@ import (
 // ErrInitialCommitFailed indicates the initial commit when making a new extension failed.
 var ErrInitialCommitFailed = errors.New("initial commit failed")
 
+const darwinAmd64 = "darwin-amd64"
+
 type Manager struct {
 	dataDir    func() string
 	lookPath   func(string) (string, error)
@@ -266,13 +268,16 @@ func (m *Manager) installBin(repo ghrepo.Interface, target string) error {
 	// if using an ARM-based Mac and an arm64 binary is unavailable, fall back to amd64 if a relevant binary is available and Rosetta 2 is installed
 	if asset == nil && isMacARM {
 		for _, a := range r.Assets {
-			if strings.HasSuffix(a.Name, "darwin-amd64") {
+			if strings.HasSuffix(a.Name, darwinAmd64) {
 				if !hasRosetta() {
 					return fmt.Errorf(
-						"%[1]s unsupported for %[2]s. Install Rosetta with `softwareupdate --install-rosetta` to use the available darwin-amd64 binary, or open an issue: `gh issue create -R %[3]s/%[1]s -t'Support %[2]s'`",
-						repo.RepoName(), platform, repo.RepoOwner())
+						"%[1]s unsupported for %[2]s. Install Rosetta with `softwareupdate --install-rosetta` to use the available %[3]s binary, or open an issue: `gh issue create -R %[4]s/%[1]s -t'Support %[2]s'`",
+						repo.RepoName(), platform, darwinAmd64, repo.RepoOwner())
 				}
 
+				fallbackMessage := fmt.Sprintf("%[1]s not available for %[2]s. Falling back to compatible %[3]s binary", repo.RepoName(), platform, darwinAmd64)
+				fmt.Fprintln(m.io.Out, fallbackMessage)
+
 				asset = &a
 				break
 			}


Test patch:
diff --git a/pkg/cmd/extension/manager_test.go b/pkg/cmd/extension/manager_test.go
index 0ad8e991e..e25bc1496 100644
--- a/pkg/cmd/extension/manager_test.go
+++ b/pkg/cmd/extension/manager_test.go
@@ -1098,7 +1098,7 @@ func TestManager_Install_amd64_when_supported(t *testing.T) {
 	assert.NoError(t, err)
 	assert.Equal(t, "FAKE BINARY", string(fakeBin))
 
-	assert.Equal(t, "", stdout.String())
+	assert.Equal(t, "gh-bin-ext not available for darwin-arm64. Falling back to compatible darwin-amd64 binary\n", stdout.String())
 	assert.Equal(t, "", stderr.String())
 }
Repository: cli/cli
Pull request #9876 (2024-11-04 15:56:24)

Fix verbiage for deleting workflow runs
It's not deleting _workflows_ (which are specified in YAML), so the message was a bit confusing.


Patch:
diff --git a/pkg/cmd/run/delete/delete.go b/pkg/cmd/run/delete/delete.go
index b785b5f0f..711e98c02 100644
--- a/pkg/cmd/run/delete/delete.go
+++ b/pkg/cmd/run/delete/delete.go
@@ -133,7 +133,7 @@ func runDelete(opts *DeleteOptions) error {
 		return err
 	}
 
-	fmt.Fprintf(opts.IO.Out, "%s Request to delete workflow submitted.\n", cs.SuccessIcon())
+	fmt.Fprintf(opts.IO.Out, "%s Request to delete workflow run submitted.\n", cs.SuccessIcon())
 	return nil
 }
 


Test patch:
diff --git a/acceptance/testdata/workflow/run-delete.txtar b/acceptance/testdata/workflow/run-delete.txtar
index 72d098740..b78135330 100644
--- a/acceptance/testdata/workflow/run-delete.txtar
+++ b/acceptance/testdata/workflow/run-delete.txtar
@@ -40,7 +40,7 @@ exec gh run watch $RUN_ID --exit-status
 
 # Delete the workflow run
 exec gh run delete $RUN_ID
-stdout '✓ Request to delete workflow submitted.'
+stdout '✓ Request to delete workflow run submitted.'
 
 # It takes some time for a workflow run to be deleted
 sleep 5
diff --git a/pkg/cmd/run/delete/delete_test.go b/pkg/cmd/run/delete/delete_test.go
index 3ded01182..5df69aa60 100644
--- a/pkg/cmd/run/delete/delete_test.go
+++ b/pkg/cmd/run/delete/delete_test.go
@@ -110,7 +110,7 @@ func TestRunDelete(t *testing.T) {
 					httpmock.REST("DELETE", fmt.Sprintf("repos/OWNER/REPO/actions/runs/%d", shared.SuccessfulRun.ID)),
 					httpmock.StatusStringResponse(204, ""))
 			},
-			wantOut: "✓ Request to delete workflow submitted.\n",
+			wantOut: "✓ Request to delete workflow run submitted.\n",
 		},
 		{
 			name: "not found",
@@ -153,7 +153,7 @@ func TestRunDelete(t *testing.T) {
 					httpmock.REST("DELETE", fmt.Sprintf("repos/OWNER/REPO/actions/runs/%d", shared.SuccessfulRun.ID)),
 					httpmock.StatusStringResponse(204, ""))
 			},
-			wantOut: "✓ Request to delete workflow submitted.\n",
+			wantOut: "✓ Request to delete workflow run submitted.\n",
 		},
 	}
Repository: cli/cli
Pull request #10194 (2025-01-07 11:03:28)

feat: make the extension upgrade fancier
This left-pad the extension names during upgrade so they all align nicely. It makes easier to see what is happening.

```bash
$ gh ext upgrade --all
[combine-prs]: already up to date
[copilot]: already up to date
[deflake]: already up to date
[edit]: already up to date
[exact]: already up to date
[not]: already up to date
[pr-repl]: already up to date
[shell]: already up to date
[slack]: already up to date
✓ Successfully checked extension upgrades

$ go run cmd/gh/main.go ext upgrade --all 
[combine-prs]: already up to date
[    copilot]: already up to date
[    deflake]: already up to date
[       edit]: already up to date
[      exact]: already up to date
[        not]: already up to date
[    pr-repl]: already up to date
[      shell]: already up to date
[      slack]: already up to date
✓ Successfully checked extension upgrades
```


Patch:
diff --git a/pkg/cmd/extension/manager.go b/pkg/cmd/extension/manager.go
index 269d58ae0..49c448b7e 100644
--- a/pkg/cmd/extension/manager.go
+++ b/pkg/cmd/extension/manager.go
@@ -469,9 +469,18 @@ func (m *Manager) Upgrade(name string, force bool) error {
 }
 
 func (m *Manager) upgradeExtensions(exts []*Extension, force bool) error {
+	var longestExtName = 0
+	for _, ext := range exts {
+		l := len(ext.Name())
+		if len(ext.Name()) > longestExtName {
+			longestExtName = l
+		}
+	}
+	format := fmt.Sprintf("[%%%ds]: ", longestExtName)
+
 	var failed bool
 	for _, f := range exts {
-		fmt.Fprintf(m.io.Out, "[%s]: ", f.Name())
+		fmt.Fprintf(m.io.Out, format, f.Name())
 		currentVersion := displayExtensionVersion(f, f.CurrentVersion())
 		err := m.upgradeExtension(f, force)
 		if err != nil {


Test patch:
diff --git a/pkg/cmd/extension/manager_test.go b/pkg/cmd/extension/manager_test.go
index 025d6e125..b83f17185 100644
--- a/pkg/cmd/extension/manager_test.go
+++ b/pkg/cmd/extension/manager_test.go
@@ -256,7 +256,7 @@ func TestManager_UpgradeExtensions(t *testing.T) {
 		`
 		[hello]: upgraded from old vers to new vers
 		[local]: local extensions can not be upgraded
-		[two]: upgraded from old vers to new vers
+		[  two]: upgraded from old vers to new vers
 		`,
 	), stdout.String())
 	assert.Equal(t, "", stderr.String())
@@ -293,7 +293,7 @@ func TestManager_UpgradeExtensions_DryRun(t *testing.T) {
 		`
  		[hello]: would have upgraded from 0 to 1
  		[local]: local extensions can not be upgraded
- 		[two]: would have upgraded from 2 to 3
+ 		[  two]: would have upgraded from 2 to 3
  		`,
 	), stdout.String())
 	assert.Equal(t, "", stderr.String())
Repository: cli/cli
Pull request #8209 (2023-10-17 21:33:25)

Bump cpuguy83/go-md2man from 2.0.1 to 2.0.3
Version 2.0.3 introduces a fix in PR https://github.com/cpuguy83/go-md2man/pull/105 that breaks a test for gen-doc, thus requires a small change in the test.

<!--
  Thank you for contributing to GitHub CLI!
  To reference an open issue, please write this in your description: `Fixes #NUMBER`
-->


cliAutomation: Hi! Thanks for the pull request. Please ensure that this change is linked to an issue by mentioning an issue number in the description of the pull request. If this pull request would close the issue, please put the word 'Fixes' before the issue number somewhere in the pull request body. If this is a tiny change like fixing a typo, feel free to ignore this message.
samcoe: @mikelolasagasti Looks like there is a linter error that needs to be addressed before this can be merged. You just need to run `go mod tidy` locally and commit the changes. 

Patch:
diff --git a/go.mod b/go.mod
index 5d3433b1e..0b243e413 100644
--- a/go.mod
+++ b/go.mod
@@ -12,7 +12,7 @@ require (
 	github.com/cli/go-gh/v2 v2.3.0
 	github.com/cli/oauth v1.0.1
 	github.com/cli/safeexec v1.0.1
-	github.com/cpuguy83/go-md2man/v2 v2.0.2
+	github.com/cpuguy83/go-md2man/v2 v2.0.3
 	github.com/creack/pty v1.1.18
 	github.com/gabriel-vasile/mimetype v1.4.3
 	github.com/gdamore/tcell/v2 v2.5.4
diff --git a/go.sum b/go.sum
index dfd6acc5d..e0989c87d 100644
--- a/go.sum
+++ b/go.sum
@@ -36,6 +36,8 @@ github.com/cli/shurcooL-graphql v0.0.3 h1:CtpPxyGDs136/+ZeyAfUKYmcQBjDlq5aqnrDCW
 github.com/cli/shurcooL-graphql v0.0.3/go.mod h1:tlrLmw/n5Q/+4qSvosT+9/W5zc8ZMjnJeYBxSdb4nWA=
 github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w=
 github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
+github.com/cpuguy83/go-md2man/v2 v2.0.3 h1:qMCsGGgs+MAzDFyp9LpAe1Lqy/fY/qCovCm0qnXZOBM=
+github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
 github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
 github.com/creack/pty v1.1.17/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4=
 github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY=


Test patch:
diff --git a/cmd/gen-docs/main_test.go b/cmd/gen-docs/main_test.go
index 312f7bc99..98f9f2fd5 100644
--- a/cmd/gen-docs/main_test.go
+++ b/cmd/gen-docs/main_test.go
@@ -18,7 +18,7 @@ func Test_run(t *testing.T) {
 	if err != nil {
 		t.Fatalf("error reading `gh-issue-create.1`: %v", err)
 	}
-	if !strings.Contains(string(manPage), `\fB\fCgh issue create`) {
+	if !strings.Contains(string(manPage), `\fBgh issue create`) {
 		t.Fatal("man page corrupted")
 	}