.nh .TH "glab" "1" "Apr 2024" "Auto generated by spf13/cobra" "" .SH NAME .PP glab-release-create - Create a new or update a GitLab Release for a repository .SH SYNOPSIS .PP \fBglab release create [\&...] [flags]\fP .SH DESCRIPTION .PP Create a new or update a GitLab Release for a repository. .PP If the release already exists, glab updates the release with the new info provided. .PP If a Git tag specified does not yet exist, the release will automatically get created from the latest state of the default branch and tagged with the specified tag name. Use \fB\fC--ref\fR to override this. The \fB\fCref\fR can be a commit SHA, another tag name, or a branch name. To fetch the new tag locally after the release, do \fB\fCgit fetch --tags origin\fR\&. .PP To create a release from an annotated Git tag, first create one locally with Git, push the tag to GitLab, then run this command. .PP Developer level access to the project is required to create a release. .SH OPTIONS .PP \fB-a\fP, \fB--assets-links\fP="" \fB\fCJSON\fR string representation of assets links (e.g. \fB\fC--assets-links='[{"name": "Asset1", "url":"https:///some/location/1", "link_type": "other", "direct_asset_path": "path/to/file"}]')\fR .PP \fB-m\fP, \fB--milestone\fP=[] The title of each milestone the release is associated with .PP \fB-n\fP, \fB--name\fP="" The release name or title .PP \fB-N\fP, \fB--notes\fP="" The release notes/description. You can use Markdown .PP \fB-F\fP, \fB--notes-file\fP="" Read release notes \fB\fCfile\fR\&. Specify \fB\fC-\fR as value to read from stdin .PP \fB-r\fP, \fB--ref\fP="" If a tag specified doesn't exist, the release is created from ref and tagged with the specified tag name. It can be a commit SHA, another tag name, or a branch name. .PP \fB-D\fP, \fB--released-at\fP="" The \fB\fCdate\fR when the release is/was ready. Defaults to the current datetime. Expected in ISO 8601 format (2019-03-15T08:00:00Z) .SH OPTIONS INHERITED FROM PARENT COMMANDS .PP \fB--help\fP[=false] Show help for command .PP \fB-R\fP, \fB--repo\fP="" Select another repository using the \fB\fCOWNER/REPO\fR or \fB\fCGROUP/NAMESPACE/REPO\fR format or full URL or git URL .SH EXAMPLE .PP .RS .nf Interactively create a release $ glab release create v1.0.1 Non-interactively create a release by specifying a note $ glab release create v1.0.1 --notes "bugfix release" Use release notes from a file $ glab release create v1.0.1 -F changelog.md Upload a release asset with a display name (type will default to 'other') $ glab release create v1.0.1 '/path/to/asset.zip#My display label' Upload a release asset with a display name and type $ glab release create v1.0.1 '/path/to/asset.png#My display label#image' Upload all assets in a specified folder (types will default to 'other') $ glab release create v1.0.1 ./dist/* Upload all tarballs in a specified folder (types will default to 'other') $ glab release create v1.0.1 ./dist/*.tar.gz Create a release with assets specified as JSON object $ glab release create v1.0.1 --assets-links=' [ { "name": "Asset1", "url":"https:///some/location/1", "link_type": "other", "direct_asset_path": "path/to/file" } ]' .fi .RE .SH SEE ALSO .PP \fBglab-release(1)\fP