Type to search…

Release

GitLab release functionality is flexible, able to be configured to match your workflow.

Introducció

Create a release to package your project at critical milestones. Releases combine code, binaries, documentation, and release notes into a complete snapshot of your project. When a release is created, GitLab automatically tags your code, archives a snapshot, and generates audit-ready evidence. This creates a permanent record that’s perfect for compliance requirements and can give your users confidence in your development process

Gitlab - Release

Glab

glab release

Crea un projecte test-release amb Glab

ps
glab repo create test-release
cd test-realease

Crea un “release” de manera interactiva

ps
glab release create 0.0.1

Create a release non-interactively by specifying a note

ps
glab release create 0.0.2 --notes "Hello World!"

Creating a release by using a CI/CD job

You can create a release directly as part of the GitLab CI/CD pipeline by using the release keyword in the job definition. You should likely create a release as one of the last steps in your CI/CD pipeline.

The release is created only if the job processes without error. If the API returns an error during release creation, the release job fails.

To authenticate your installation of glab with a CI job token, the glab command must be run in a GitLab CI job.

The token is automatically provided by the GitLab Runner via the CI_JOB_TOKEN environment variable.

shell
glab auth login --job-token $CI_JOB_TOKEN --hostname $CI_SERVER_HOST --api-protocol $CI_SERVER_PROTOCOL
GITLAB_HOST=$CI_SERVER_URL glab release list -R $CI_PROJECT_PATH

You're reading a preview.

Sign in to read the full article. Any account opens 10 free articles a month; students and teachers read their course pages without limit.

Sign in