GH-DISCUSSION-EDIT(1)
π gh-discussion-edit(1) π
ok so this is a page from the GitHub CLI manual β welcome to the discussion-edit zone bestie, it's giving preview energy β¨
β¨ NAME β¨
gh-discussion-edit β literally edits a discussion (and yes it's still in preview, we're early adopters π
)
π¦ SYNOPSIS π¦
gh discussion edit {<number> | <discussion-url>} [flags]
k so you feed it either a <number> or a <discussion-url>, and then any [flags] you want. pick your fighter π«Ά
πΈ DESCRIPTION πΈ
Edits a GitHub Discussion. that's the whole thing. iconic behavior, no notes π
Here's the tea though: if you don't pass any flags, the command runs interactively when it's connected to a terminal β so it just opens up and asks you stuff like a little chat π§
Wanna be all business instead? Use flags to update specific fields non-interactively. main character energy either way π
π OPTIONS π
--add-label <name>β adds labels by name β¨-b,--body <string>β the new body for the discussion, fresh out the group chat π¬-F,--body-file <string>β reads the body text from a file (and psst: use"-"to read from standard input) π-c,--category <string>β the new category name or slug for the discussion, your pick π--remove-label <name>β removes labels by name, bye bestie π-R,--repo <[HOST/]OWNER/REPO>β select another repository using the[HOST/]OWNER/REPOformat π-t,--title <string>β the new title for the discussion, make it catchy π¦
π EXIT CODES π
know your numbers, iykyk:
0β Successful execution π1β Error π2β Command canceled π4β Authentication required π
NOTE: Specific commands may have additional exit codes. Refer to the command's help for more information. (fr fr, always check the help π«Ά)
β EXAMPLE β
# Edit interactively
$ gh discussion edit 123
# Update title, body, and category
$ gh discussion edit 123 --title "Updated title" --body "Updated body" --category "Ideas"
# Update body from a file
$ gh discussion edit 123 --body-file body.md
# Add and remove labels
$ gh discussion edit 123 --add-label "bug,help wanted" --remove-label "stale"
see how easy that was?? ate and left no crumbs π₯
π SEE ALSO π
gh-discussion(1)β go read the parent page bestie, it's the vibe check you need π
that's a wrap! this was GitHub CLI v2.102.0, dated Oct 2026 β tysm for reading, mwah, go edit some discussions πΈππ
π¦ where this page comes from
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- opensuse-leap 16.0: gh 2.102.0-bp160.1.1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms