.gitlab-ci.yml 1.57 KB
Newer Older
Yann Leboulanger's avatar
Yann Leboulanger committed
1
before_script:
Yann Leboulanger's avatar
Yann Leboulanger committed
2
  - sudo apt-get update -qq && sudo apt-get install -y -qq libtool pkg-config python3-openssl gir1.2-gtk-3.0 python3-gi python3-nbxmpp-nightly pylint3
Yann Leboulanger's avatar
Yann Leboulanger committed
3 4 5 6 7 8 9 10 11
  - sudo apt-get build-dep -y -qq gajim-default-nightly

stages:
  - test
  - build

run-test:
  stage: test
  script:
12
    - python3 setup.py test_nogui
Yann Leboulanger's avatar
Yann Leboulanger committed
13

Yann Leboulanger's avatar
Yann Leboulanger committed
14 15 16
run-pylint:
  stage: test
  script:
17
    - pylint3 --additional-builtins=_ --disable=all --enable=E0001,E0011,E0012,E0100,E0101,E0102,E0103,E0104,E0105,E0106,E0107,E0108,E0202,E0221,E0222,E0235,E0501,E0502,E0503,E0602,E0603,E0604,E0701,E0702,E1001,E1002,E1003,E1004,E1111,E1120,E1121,E1122,E1123,E1124,E1125,E1200,E1201,E1205,E1206,E1300,E1301,E1302,E1303,E1304,E1305,E1306,E1310,E1700,E1701,W0102 gajim
Yann Leboulanger's avatar
Yann Leboulanger committed
18

Yann Leboulanger's avatar
Yann Leboulanger committed
19 20 21
run-build:
  stage: build
  script:
André's avatar
André committed
22 23
    - python3 setup.py sdist
    - cd dist
Yann Leboulanger's avatar
Yann Leboulanger committed
24 25 26 27 28 29 30 31
    - export FN="gajim-default-"$(date +%F)".tar"
    - mv gajim-*.tar.gz $FN.gz
    - mkdir tmp_add_plugins
    - mv $FN.gz tmp_add_plugins/
    - cd tmp_add_plugins/
    - tar xzf $FN.gz
    - rm $FN.gz
    - export GF=$(find . -maxdepth 1 -type d -name 'gajim-*')
32 33
    - mkdir -p $GF/gajim/data/plugins/
    - cd $GF/gajim/data/plugins/
Yann Leboulanger's avatar
Yann Leboulanger committed
34 35 36
    - curl -O https://ftp.gajim.org/plugins_1/plugin_installer.zip
    - unzip plugin_installer.zip
    - rm plugin_installer.zip
37
    - cd ../../../..
Yann Leboulanger's avatar
Yann Leboulanger committed
38 39 40
    - tar czf ../$FN.gz gajim-*
    - cd ..
    - rm -rf tmp_add_plugins
Yann Leboulanger's avatar
Yann Leboulanger committed
41
    - scp $FN.gz panoramix:/var/www/gajim/downloads/snap/ci/gajim-default-$CI_COMMIT_SHA.tar.gz
Yann Leboulanger's avatar
Yann Leboulanger committed
42 43 44 45 46 47

  artifacts:
    name: "gajim-default-$CI_COMMIT_REF_NAME-$CI_COMMIT_SHA"
    expire_in: 1 week
    paths:
      - gajim-default-2???-??-??.tar.gz