ci: Add dist job

So far, releases are done locally by invoking `meson dist`.

We can do better and leverage the existing CI infrastructure, to get
to the following release workflow:

 - bump version in meson.build, update NEWS etc.
 - open merge request for the release
 - merge when the pipeline (including dist check) succeeds
 - tag the release
 - wait for the tag pipeline to spit out the tarball artifact

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1980>
This commit is contained in:
Florian Müllner 2021-08-31 11:54:30 +02:00
parent 4bbe61d47e
commit 08a3fc99a2

View File

@ -9,6 +9,7 @@ stages:
- build - build
- test - test
- analyze - analyze
- deploy
variables: variables:
FDO_UPSTREAM_REPO: GNOME/mutter FDO_UPSTREAM_REPO: GNOME/mutter
@ -344,3 +345,28 @@ test-mutter-coverity:
key: coverity-tarball key: coverity-tarball
paths: paths:
- coverity - coverity
dist-mutter:
extends:
- .fdo.distribution-image@fedora
- .mutter.fedora:34@x86_64
<<: *test-setup
stage: deploy
needs:
- build-mutter@x86_64
script:
- dbus-run-session -- xvfb-run -a -s "$XVFB_SERVER_ARGS" meson dist -C build
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
changes:
- "**/meson.build"
- meson/*
dist-mutter-tarball:
extends: dist-mutter
artifacts:
expose_as: 'Get tarball here'
paths:
- build/meson-dist/$CI_PROJECT_NAME-$CI_COMMIT_TAG.tar.xz
rules:
- if: '$CI_COMMIT_TAG'