.gitlab-ci.yml 1.56 KB
Newer Older
1 2
include: 'https://gitlab.gnome.org/GNOME/citemplates/raw/master/flatpak/flatpak_ci_initiative.yml'

3 4 5 6
cache:
  paths:
    - _ccache/

7 8 9 10 11 12
variables:
  BUNDLE: 'epiphany-git.flatpak'
  MANIFEST_PATH: 'org.gnome.Epiphany.json'
  RUNTIME_REPO: 'https://nightly.gnome.org/gnome-nightly.flatpakrepo'
  FLATPAK_MODULE: 'epiphany'
  APP_ID: 'org.gnome.Epiphany.Devel'
13

14
stages:
15
  - test
16

17
check-code-style:
18
  stage: .pre
19
  image: alpine:latest
20
  interruptible: true
21 22
  before_script:
    - apk update && apk add uncrustify bash python3
23
  script:
24
    - bash data/check-code-style
25

26
flatpak:
27
  extends: '.flatpak'
28
  variables:
29
    CONFIG_OPTS: '-Dprofile=Devel -Dunit_tests=enabled --werror -Dgsb_api_key=${GSB_API_KEY} -Denable_gsb=true'
30 31 32
  except:
    - master

33 34
flatpak master:
  extends: '.flatpak'
35
  variables:
36
    CONFIG_OPTS: '-Dtech_preview=true -Dprofile=Devel -Dgsb_api_key=${GSB_API_KEY} -Denable_gsb=true'
37 38 39
  only:
    - master

40 41
flatpak scanbuild:
  extends: '.flatpak'
42
  variables:
43
    CONFIG_OPTS: '-Dprofile=Devel -Dunit_tests=enabled --werror'
44
  script:
Michael Catanzaro's avatar
Michael Catanzaro committed
45
    - flatpak-builder --user --disable-rofiles-fuse --stop-at=${FLATPAK_MODULE} flatpak_app ${MANIFEST_PATH}
46
    - flatpak build flatpak_app meson --prefix=/app ${CONFIG_OPTS} _build
47 48 49 50 51 52
    - flatpak build flatpak_app ninja -C _build scan-build
    - bash -c 'if [[ -n "$(ls -A _build/meson-logs/scanbuild/)" ]]; then echo "Scan build log found, assuming defects exist"; exit 1; fi'
  artifacts:
    when: on_failure
    paths:
      - _build/meson-logs/scanbuild
53 54 55

nightly:
  extends: '.publish_nightly'
56
  stage: .post
57
  dependencies: ['flatpak master']