File: .gitlab-ci.yml

package info (click to toggle)
gitg 3.30.1-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, sid
  • size: 18,520 kB
  • sloc: ansic: 1,635; ruby: 1,466; sh: 314; python: 259; xml: 121; makefile: 40
file content (82 lines) | stat: -rw-r--r-- 2,162 bytes parent folder | download | duplicates (2)
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
stages:
- test
- review
- deploy

variables:
    BUNDLE: "gitg-git.flatpak"

flatpak:
    image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
    stage: test

    variables:
        # Replace with your manifest path
        MANIFEST_PATH: "org.gnome.gitg.json"
        RUNTIME_REPO: "https://sdk.gnome.org/gnome-nightly.flatpakrepo"
        FLATPAK_MODULE: "gitg"
        MESON_ARGS: "-Ddeprecations=true --buildtype=debugoptimized -Ddocs=true"
        DBUS_ID: "org.gnome.gitg"

    script:
        - flatpak-builder --stop-at=${FLATPAK_MODULE} app ${MANIFEST_PATH}
        - flatpak build app meson --prefix=/app ${MESON_ARGS} _build
        - flatpak build app ninja -C _build install

        # Build the docs
        - flatpak build app ninja -C _build libgitg-ext-docs
        - mv docs/ public/

        - flatpak-builder --finish-only --repo=repo app ${MANIFEST_PATH}
        - xvfb-run -a -s "-screen 0 1024x768x24" flatpak build app ninja -C _build test
        - flatpak build-bundle repo ${BUNDLE} --runtime-repo=${RUNTIME_REPO} ${DBUS_ID}

    artifacts:
        paths:
            - ${BUNDLE}
            - public/
            - _build/meson-logs/meson-log.txt
            - _build/meson-logs/testlog.txt
        expire_in: 6 hours

    cache:
        paths:
             - .flatpak-builder/cache

review:
    stage: review
    dependencies:
        - flatpak
    script:
        - echo "Generating flatpak deployment"
    artifacts:
        paths:
            - ${BUNDLE}
        expire_in: 30 days
    environment:
        name: review/$CI_COMMIT_REF_NAME
        url: https://gitlab.gnome.org/$CI_PROJECT_PATH/-/jobs/$CI_JOB_ID/artifacts/raw/${BUNDLE}
        on_stop: stop_review

stop_review:
    stage: review
    script:
        - echo "Stopping flatpak deployment"
    when: manual
    environment:
        name: review/$CI_COMMIT_REF_NAME
        action: stop

pages:
    image: registry.gitlab.gnome.org/gnome/gnome-runtime-images/gnome:master
    stage: deploy
    dependencies:
      - flatpak
    script:
      - echo "Deploying docs"
    artifacts:
        paths:
            - public
    only:
        - master