gh-pr-comment

Add comments to pull requests

TLDR

Add comment to PR
$ gh pr comment [number] -b "[comment]"
Comment interactively
$ gh pr comment [number]
Comment from file
$ gh pr comment [number] -F [comment.md]
Edit last comment
$ gh pr comment [number] --edit-last -b "[new text]"

SYNOPSIS

gh pr comment [number] [options]

DESCRIPTION

gh pr comment adds comments to pull requests from the command line. It provides flexible options for composing comments, including inline text, file input, and interactive editing.When called without the --body flag, the command opens your default editor for composing the comment. Comments support full GitHub-flavored Markdown including code blocks, tables, task lists, and @ mentions. The --edit-last option allows modifying your most recent comment on a pull request.

PARAMETERS

-b, --body text

Comment body.
-F, --body-file file
Read body from file.
--edit-last
Edit last comment.
-R, --repo owner/repo
Repository.

INSTALL

sudo apt install gh
sudo dnf install gh
sudo pacman -S github-cli
sudo apk add github-cli
sudo zypper install gh
brew install gh
nix profile install nixpkgs#gh

SEE ALSO

gh-pr(1)