.gitlab-ci.yml 1.73 KB
Newer Older
Isaak Lim's avatar
Isaak Lim committed
1 2 3 4 5
stages:
  - build
  - test
  - deploy

Isaak Lim's avatar
Isaak Lim committed
6
build-3.5-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
7 8
  stage:
    build
9 10
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
11
    - Apple
12 13
  variables:
    GIT_SUBMODULE_STRATEGY: recursive
Isaak Lim's avatar
Isaak Lim committed
14
  script:
Isaak Lim's avatar
Isaak Lim committed
15
    - export PATH=/opt/local/bin:$PATH
Isaak Lim's avatar
Isaak Lim committed
16 17
    - virtualenv --clear -p python3.5 .
    - source bin/activate
Isaak Lim's avatar
Isaak Lim committed
18 19 20 21
    - python setup.py bdist_wheel --dist-dir dist3
  artifacts:
    paths:
      - dist3/
Isaak Lim's avatar
Isaak Lim committed
22

Isaak Lim's avatar
Isaak Lim committed
23
build-2.7-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
24 25
  stage:
    build
26 27
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
28
    - Apple
29 30
  variables:
    GIT_SUBMODULE_STRATEGY: recursive
Isaak Lim's avatar
Isaak Lim committed
31
  script:
Isaak Lim's avatar
Isaak Lim committed
32
    - export PATH=/opt/local/bin:$PATH
Isaak Lim's avatar
Isaak Lim committed
33 34
    - virtualenv --clear -p python2.7 .
    - source bin/activate
Isaak Lim's avatar
Isaak Lim committed
35 36 37 38 39
    - python setup.py bdist_wheel --dist-dir dist2
  artifacts:
    paths:
      - dist2/

Isaak Lim's avatar
Isaak Lim committed
40
test-3.5-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
41 42 43 44
  stage:
    test
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
45
    - Apple
Isaak Lim's avatar
Isaak Lim committed
46
  dependencies:
Isaak Lim's avatar
Isaak Lim committed
47
    - build-3.5-linux-macos
Isaak Lim's avatar
Isaak Lim committed
48
  script:
Isaak Lim's avatar
Isaak Lim committed
49
    - export PATH=/opt/local/bin:$PATH
Isaak Lim's avatar
Isaak Lim committed
50 51 52
    - virtualenv --clear -p python3.5 .
    - source bin/activate
    - pip install dist3/*.whl
Isaak Lim's avatar
Isaak Lim committed
53 54 55
    - cd tests
    - python -m unittest discover

Isaak Lim's avatar
Isaak Lim committed
56
test-2.7-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
57 58 59 60
  stage:
    test
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
61
    - Apple
Isaak Lim's avatar
Isaak Lim committed
62
  dependencies:
Isaak Lim's avatar
Isaak Lim committed
63
    - build-2.7-linux-macos
Isaak Lim's avatar
Isaak Lim committed
64
  script:
Isaak Lim's avatar
Isaak Lim committed
65
    - export PATH=/opt/local/bin:$PATH
Isaak Lim's avatar
Isaak Lim committed
66 67 68
    - virtualenv --clear -p python2.7 .
    - source bin/activate
    - pip install dist2/*.whl
Isaak Lim's avatar
Isaak Lim committed
69 70 71
    - cd tests
    - python -m unittest discover

Isaak Lim's avatar
Isaak Lim committed
72
deploy-3.5-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
73 74 75 76
  stage:
    deploy
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
77
    - Apple
Isaak Lim's avatar
Isaak Lim committed
78
  dependencies:
Isaak Lim's avatar
Isaak Lim committed
79
    - build-3.5-linux-macos
Isaak Lim's avatar
Isaak Lim committed
80 81 82 83 84 85 86
  script:
    - mkdir release
    - cp dist3/*.whl release
  artifacts:
    paths:
      - release/*.whl

Isaak Lim's avatar
Isaak Lim committed
87
deploy-2.7-linux-macos:
Isaak Lim's avatar
Isaak Lim committed
88 89 90 91
  stage:
    deploy
  tags:
    - Linux
Isaak Lim's avatar
Isaak Lim committed
92
    - Apple
Isaak Lim's avatar
Isaak Lim committed
93
  dependencies:
Isaak Lim's avatar
Isaak Lim committed
94
    - build-2.7-linux-macos
Isaak Lim's avatar
Isaak Lim committed
95 96 97 98 99 100
  script:
    - mkdir release
    - cp dist2/*.whl release
  artifacts:
    paths:
      - release/*.whl