summaryrefslogtreecommitdiff
path: root/.gitlab-ci.yml
blob: 974fb544099dfac0ac974c8887920209961fe87e (plain)
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
stages:
  - 'build'
  - 'deploy'

.build:
  image: 'registry.fedoraproject.org/fedora:37'
  stage: 'build'
  variables:
    CCACHE_BASEDIR: "${CI_PROJECT_DIR}"
    CCACHE_DIR: "${CI_PROJECT_DIR}/_ccache"
    DEPS: >-
      gcc
      ccache
      gettext
      meson
      ninja-build
      redhat-rpm-config
      glib2-devel
      gobject-introspection-devel
      python3-devel
      python3-packaging
      xorg-x11-server-Xvfb
      git
      pip
      luajit-devel
      lua-lgi-compat
      gi-docgen
      vala
  before_script:
    - "dnf install -y $DEPS"
    - 'mkdir -p _ccache'
    - 'ccache --zero-stats'
    - 'ccache --show-stats'
    - 'pip install markdown markupsafe pygments jinja2 toml typogrify'
  after_script:
    - 'ccache --show-stats'
  cache:
    key: "$CI_JOB_NAME"
    paths:
      - '_ccache/'

build peas:
  extends: '.build'
  script:
    - 'meson -Dintrospection=true -Dvapi=true -Dgtk_doc=false _build .'
    - 'ninja -C _build test'

reference:
  extends: '.build'
  variables:
    MESON_ARGS: >-
      -Dgtk_doc=true
  script:
    - mkdir -p _reference/libpeas-2
    - meson ${MESON_ARGS} _build
    - ninja -C _build
    - mv _build/docs/reference/libpeas-2/* _reference/libpeas-2
  artifacts:
    paths:
      - _reference

pages:
  stage: deploy
  needs: ['reference']
  script:
    - mv _reference public
  artifacts:
    when: on_success
    paths:
      - public