Update GitLab CI to save changelog to CHANGELOG file
This commit is contained in:
parent
cec51554d0
commit
c2b8dc716b
1 changed files with 3 additions and 4 deletions
|
|
@ -4,10 +4,9 @@ stages:
|
|||
create_release:
|
||||
stage: release
|
||||
image: registry.gitlab.com/gitlab-org/release-cli:latest
|
||||
only:
|
||||
- tags
|
||||
rules:
|
||||
- if: $CI_COMMIT_TAG =~ /^[0-9]+\.[0-9]+\.[0-9]+.*$/
|
||||
- when: never
|
||||
script:
|
||||
- |
|
||||
# Get the previous tag to generate changelog
|
||||
|
|
@ -21,9 +20,9 @@ create_release:
|
|||
fi
|
||||
|
||||
# Save changelog to file for release
|
||||
echo -e "## Changes\n$CHANGELOG" > changelog.md
|
||||
echo -e "## Changes\n$CHANGELOG" > CHANGELOG
|
||||
release:
|
||||
name: 'Release $CI_COMMIT_TAG'
|
||||
tag_name: '$CI_COMMIT_TAG'
|
||||
description: './changelog.md'
|
||||
description: './CHANGELOG'
|
||||
ref: '$CI_COMMIT_TAG'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue