LinuxCommandLibrary
GitHubF-DroidGoogle Play Store

gh-issue-create

create new GitHub issues with metadata

TLDR

Create an issue interactively
$ gh issue create
copy
Create with title and body
$ gh issue create -t "[title]" -b "[body]"
copy
Read the body from a file (use - for stdin)
$ gh issue create -t "[title]" -F [body.md]
copy
Open the editor to compose the issue
$ gh issue create -e
copy
Add labels and assignees
$ gh issue create -t "[title]" -l [bug] -l [urgent] -a [@me]
copy
Use an issue template by name
$ gh issue create -T "[Bug report]"
copy
Target a specific repository
$ gh issue create -R [owner/repo] -t "[title]"
copy
Open the browser form
$ gh issue create -w
copy

SYNOPSIS

gh issue create [options]

DESCRIPTION

gh issue create files a new issue on GitHub with comprehensive metadata support. Without flags it walks through an interactive prompt for title, body, labels, assignees, and project assignment. With flags, every field can be supplied non-interactively for use in scripts and CI.Issue templates configured on the repository can be selected with -T/--template by name; the template body is used as the starting text. -F/--body-file is convenient for piping the output of another tool (for example a generated bug report) directly into a new issue. The alias `gh issue new` is equivalent.

PARAMETERS

-t, --title string

Issue title. Prompts if omitted.
-b, --body string
Issue body. Prompts if omitted.
-F, --body-file file
Read the body from a file. Use `-` to read from stdin.
-e, --editor
Skip prompts and open `$EDITOR` to write the title and body.
-l, --label name
Add a label by name. Repeatable.
-a, --assignee login
Assign a user by login. `@me` self-assigns. Repeatable.
-m, --milestone name
Set the milestone by name.
-p, --project title
Add the issue to a project by title. Repeatable.
-T, --template name
Use an issue template by name.
--recover file
Recover input from a failed previous run.
-w, --web
Open a browser to create the issue.
-R, --repo [HOST/]OWNER/REPO
Target a specific repository.

SEE ALSO

Copied to clipboard
Kai