This repository was archived by the owner on Jul 6, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
60 lines (53 loc) · 1.41 KB
/
.gitlab-ci.yml
File metadata and controls
60 lines (53 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
image: registry.gitlab.com/coolero/coolero/pipeline:v3
variables:
POETRY_VIRTUALENVS_IN_PROJECT: "true"
cache:
key: "${CI_JOB_NAME}"
paths:
- .cache/pip
- .venv
before_script:
- python --version
- poetry --version
- poetry install
stages:
# - quality
- test
- release
#lint:
# stage: quality
# allow_failure: false
# script:
# - make lint
test:
stage: test
rules:
- if: '$CI_PIPELINE_SOURCE == "merge_request_event"'
- if: '$CI_PIPELINE_SOURCE == "push"'
script:
- xvfb-run make test
create_release:
stage: release
image: registry.gitlab.com/gitlab-org/release-cli:latest
before_script:
- echo 'Starting release job'
rules:
- if: $CI_COMMIT_TAG
script:
- echo "running release job for v${CI_COMMIT_TAG:?}"
- awk -v ver="${CI_COMMIT_TAG:?}" '/^#+ \[/ { if (p) { exit }; if ($2 == "["ver"]") { p=1; next} } p && NF' ./CHANGELOG.md > ./description.txt
release:
name: 'Coolero v$CI_COMMIT_TAG'
description: './description.txt'
tag_name: '$CI_COMMIT_TAG'
ref: '$CI_COMMIT_TAG'
milestones:
- '$CI_COMMIT_TAG'
assets:
links:
- name: 'AppImage'
url: 'https://gitlab.com/api/v4/projects/30707566/packages/generic/appimage/$CI_COMMIT_TAG/Coolero-x86_64.AppImage'
link_type: package
- name: 'Flatpak'
url: 'https://flathub.org/apps/details/org.coolero.Coolero'
link_type: package