.gitlab-ci.yml 1.08 KB
Newer Older
1
stages:
2
  - doc
3 4
  - pages

5 6 7
variables:
  APIDOC_VERSION: 0.17.6
  APIDOC_MARKDOWN2_VERSION: 0.3.3
8
  API_DOC_PATH: ./doc/en/dev_api.md
9 10 11 12 13 14 15 16 17

doc:api:
  stage: doc
  only:
    - master
  image: node:6.11.1
  artifacts:
    expire_in: 1 hour
    paths:
18
      - ./doc/en/dev_api.md
19 20 21
  script:
    - npm install -g apidoc@${APIDOC_VERSION} apidoc-markdown2@${APIDOC_MARKDOWN2_VERSION}
    - apidoc -i ./api -o /tmp/api-doc --markdown false -e node_modules
22
    - apidoc-markdown2 -p /tmp/api-doc -o ${API_DOC_PATH} -t ./doc/template/apidoc.md
23 24 25 26 27

doc:graphs:
  stage: doc
  only:
    - master
28 29 30 31 32
  image: promethe42/graphviz-dataflow-plantuml:latest
  script:
    - make -C doc dfd
    - make -C doc seq
    - make -C doc uml
33
    - make -C doc dot
34 35 36 37 38 39 40 41 42 43
  artifacts:
    expire_in: 1 hour
    paths:
      - doc/img/*.svg
      - doc/img/*.png

pages:
  stage: pages
  image: fellah/gitbook:3.2.0
  dependencies:
44 45
    - doc:graphs
    - doc:api
46 47 48 49
  cache:
    paths:
      - node_modules/
  script:
50
    - gitbook install doc
51
    - gitbook build doc public
52
  artifacts:
53
    expire_in: 1 hour
54
    paths:
55
      - public
56 57
  only:
    - master