forked from GNOME/evince
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
137 lines (112 loc) · 3.3 KB
/
.gitlab-ci.yml
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
stages:
- build
- deploy
variables:
BUNDLE: "org.gnome.Evince.flatpak"
master:
image: registry.gitlab.gnome.org/gnome/evince/master-amd64:latest
stage: build
script:
- ./autogen.sh --enable-debug --enable-nautilus
- make
artifacts:
when: on_failure
paths:
- config.log
expire_in: 2 days
meson:
image: registry.gitlab.gnome.org/gnome/evince/master-amd64:latest
stage: build
when: manual
script:
- meson _build
- ninja -C _build all
artifacts:
when: on_failure
paths:
- _build/meson-logs/meson-log.txt
expire_in: 2 days
meson-gtk-doc:
image: registry.gitlab.gnome.org/gnome/evince/master-amd64:latest
stage: build
when: manual
script:
- meson -Dgtk_doc=true _build
- ninja -C _build all libevdocument-doc libevview-doc evince-doc
artifacts:
when: on_failure
paths:
- _build/meson-logs/meson-log.txt
expire_in: 2 days
gtk-doc:
image: registry.gitlab.gnome.org/gnome/evince/master-amd64:latest
stage: build
when: manual
script:
- ./autogen.sh --enable-nautilus --enable-gtk-doc
- make
artifacts:
when: on_failure
paths:
- config.log
expire_in: 2 days
flatpak:
image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
stage: build
variables:
MANIFEST_PATH: "build-aux/flatpak/org.gnome.Evince.json"
RUNTIME_REPO: "https://sdk.gnome.org/gnome-nightly.flatpakrepo"
FLATPAK_MODULE: "evince"
MESON_ARGS: "-Dnautilus=false"
APP_ID: "org.gnome.Evince"
script:
- flatpak-builder --stop-at=evince app ${MANIFEST_PATH}
- flatpak build app meson --prefix=/app ${MESON_ARGS} _build
- flatpak build app ninja -C _build install
- flatpak-builder --finish-only --repo=_repo app ${MANIFEST_PATH}
# Run automatic tests inside the Flatpak env
- xvfb-run -a -s "-screen 0 1024x768x24" flatpak build app ninja -C _build test
- flatpak build-bundle _repo ${BUNDLE} --runtime-repo=${RUNTIME_REPO} ${APP_ID}
artifacts:
paths:
- ${BUNDLE}
- _build/meson-logs/meson-log.txt
expire_in: 2 days
cache:
paths:
- .flatpak-builder/downloads
- .flatpak-builder/git
deploy:
stage: deploy
dependencies:
- flatpak
script:
- echo "Generating flatpak deployment"
artifacts:
paths:
- ${BUNDLE}
expire_in: 2 days
environment:
name: deploy/$CI_COMMIT_REF_NAME
url: https://gitlab.gnome.org/$CI_PROJECT_PATH/-/jobs/$CI_JOB_ID/artifacts/raw/${BUNDLE}
on_stop: stop_deploy
except:
- tags
# don't run on stable branches
- /^gnome-\d-\d\d$/
# No need to run on the upstream master branch either
- master@GNOME/evince
stop_deploy:
stage: deploy
script:
- echo "Stopping flatpak deployment"
when: manual
environment:
name: deploy/$CI_COMMIT_REF_NAME
action: stop
except:
- tags
# don't run on stable branches
- /^gnome-\d-\d\d$/
# No need to run on the upstream master branch either
- master@GNOME/evince