Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
D
dcc-js
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
D-PTB
DCC
Development
dcc-js
Merge requests
!9
[CI] add release and publish pipeline
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
[CI] add release and publish pipeline
jloewe/dcc-js:ci-release-and-publish
into
master
Overview
0
Commits
7
Pipelines
0
Changes
2
Merged
Jan Loewe
requested to merge
jloewe/dcc-js:ci-release-and-publish
into
master
1 year ago
Overview
0
Commits
7
Pipelines
0
Changes
2
Expand
0
0
Merge request reports
Viewing commit
26e0605f
Prev
Next
Show latest version
2 files
+
3
−
5
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
Files
2
Search (e.g. *.vue) (Ctrl+P)
Verified
26e0605f
ci: fix yarnrc for ci
· 26e0605f
Jan Loewe
authored
1 year ago
.gitlab-ci.yml
+
54
−
0
Options
@@ -3,6 +3,8 @@ image: node:18
stages
:
-
test
-
release
-
deploy
# === Caches ===
@@ -78,3 +80,55 @@ lint:
-
yarn run test:prettier
cache
:
-
<<
:
*yarn-cache
# === Job: Prepare Release
# Description: this job prepares an env file for an upcoming release
prepare_release
:
stage
:
.pre
rules
:
-
if
:
$CI_COMMIT_TAG =~ /v.*/
script
:
-
./scripts/createReleaseEnv.sh >> release.env
artifacts
:
paths
:
-
release.description
reports
:
dotenv
:
release.env
# === Job: Release
# Description: this job creates a new release using the provided env file
# === Variables ===
# NEXT_VER: the version of the upcoming release
# === Files ===
# release.description: multi-line description of the release
release_job
:
stage
:
release
image
:
registry.gitlab.com/gitlab-org/release-cli:latest
needs
:
-
job
:
prepare_release
artifacts
:
true
rules
:
-
if
:
$CI_COMMIT_TAG =~ /v.*/
script
:
-
echo "running release_job for $NEXT_VER"
release
:
name
:
'
$NEXT_VER'
description
:
./release.description
tag_name
:
'
$NEXT_VER'
ref
:
'
$CI_COMMIT_SHA'
# === Job: Deploy
# Description: this job creates publishes the package to the gitlab package registry
# === Variables ===
# NPM_AUTH_TOKEN: a deploy token with read_package_registry and write_package_registry scopes
deploy
:
stage
:
deploy
needs
:
[
"
proxy"
]
rules
:
-
if
:
$CI_COMMIT_TAG =~ /v.*/
script
:
-
*yarn-install
-
yarn npm publish
Loading