.gitlab-ci.yml 648 Bytes
Newer Older
Plup's avatar
Plup committed
1
---
2
image: python:3.6
Plup's avatar
Plup committed
3 4

stages:
Plup's avatar
Plup committed
5 6
  - test
  - release
Plup's avatar
Plup committed
7

Plup's avatar
Plup committed
8 9
test:
  stage: test
Plup's avatar
Plup committed
10
  script:
11
    - pip install .[dev]
12
    - python -m unittest djangoldp.tests.runner
Plup's avatar
Plup committed
13 14
  except:
    - master
Plup's avatar
Plup committed
15
    - tags
Plup's avatar
Plup committed
16 17 18 19 20 21 22 23 24 25
  tags:
    - sib

publish:
  stage: release
  before_script:
    - git config user.name "${GITLAB_USER_NAME}"
    - git config user.email "${GITLAB_USER_EMAIL}"
    - git remote set-url origin "https://gitlab-ci-token:${GL_TOKEN}@git.happy-dev.fr/${CI_PROJECT_PATH}.git"
    - pip install git+https://github.com/plup/python-semantic-release
26
    - pip install sib-commit-parser
Plup's avatar
Plup committed
27 28 29 30
  script:
    - semantic-release publish
  only:
    - master
Plup's avatar
Plup committed
31 32
  tags:
    - sib