gh release create
gh release create [<tag>] [<files>...]
Create a new GitHub Release for a repository.
A list of asset files may be given to upload to the new release. To define a
display label for an asset, append text starting with
# after the file name.
If a matching git tag does not yet exist, one will automatically get created
from the latest state of the default branch.
--target to point to a different branch or commit for the automatic tag creation.
--verify-tag to abort the release if the tag doesn't already exist.
To fetch the new tag locally after the release, do
git fetch --tags origin.
To create a release from an annotated git tag, first create one locally with git, push the tag to GitHub, then run this command.
When using automatically generated release notes, a release title will also be automatically generated unless a title was explicitly passed. Additional release notes can be prepended to automatically generated notes by using the notes parameter.
- Start a discussion in the specified category
- Save the release as a draft instead of publishing it
- Automatically generate title and notes for the release
- Mark this release as "Latest" (default: automatic based on date and version)
- Release notes
- Read release notes from file (use "-" to read from standard input)
- Tag to use as the starting point for generating release notes
- Mark the release as a prerelease
- Target branch or full commit SHA (default: main branch)
- Release title
- Abort in case the git tag doesn't already exist in the remote repository
Options inherited from parent commands
- Select another repository using the [HOST/]OWNER/REPO format