Diff of /.circleci/config.yml [000000] .. [d45a3a]

Switch to unified view

a b/.circleci/config.yml
1
version: 2
2
3
variables:
4
  update_conda: &update_conda
5
    run:
6
      name: Update conda
7
      command: conda update --yes conda
8
  export_shortcuts: &export_shortcuts
9
    run:
10
      name: Export shortcuts 
11
      command: |
12
        # for no good reason the wrong version of pytest is choosen by default...
13
        echo 'export PYTEST=$(conda info --base)/envs/bpnet/bin/pytest' >> $BASH_ENV
14
        echo 'export HDF5_USE_FILE_LOCKING=FALSE' >> $BASH_ENV
15
  install_bpnet_env: &install_bpnet_env
16
    run:
17
      name: Install bpnet enviroment
18
      command: |
19
        conda env create -f conda-env.yml
20
  run_tests: &run_tests
21
    run:
22
      name: Run tests
23
      command: |
24
        source activate bpnet
25
        mkdir test-reports
26
        $PYTEST --cov=bpnet/ tests/ --disable-warnings --no-cov-on-fail --junitxml=test-reports/junit.xml
27
      no_output_timeout: 15m
28
  run_coveralls: &run_coveralls
29
    run:
30
      name: run coveralls
31
      command: |
32
        source activate bpnet
33
        coveralls || true
34
  store_test_results: &store_test_results
35
    store_test_results:
36
      path: test-reports
37
  store_test_artifacts: &store_test_artifacts
38
    store_artifacts:
39
      path: test-reports
40
      destination: test-reports
41
42
43
jobs:
44
  test-py36:
45
    docker:
46
      - image: continuumio/anaconda3:5.0.1
47
    working_directory: ~/repo
48
    steps:
49
      - checkout
50
      - *update_conda
51
      - *install_bpnet_env
52
      - *export_shortcuts
53
      - *run_tests
54
      # - *run_coveralls
55
      - *store_test_results
56
      - *store_test_artifacts
57
58
  build-deploy-docs:
59
    docker:
60
      - image: continuumio/anaconda3:5.0.1
61
    working_directory: ~/repo
62
    steps:
63
      # - add_ssh_keys:
64
      #     fingerprints:
65
      #       - e3:44:16:ec:72:df:ae:59:82:c2:ee:57:4a:52:71:aa
66
      - checkout
67
      - run:
68
          name: Install pip bpnet
69
          command: pip install -e .
70
      - run:
71
          name: Install build deps
72
          # use custom pydoc-markdown
73
          command: pip install nbconvert mkdocs git+https://github.com/kipoi/pydoc-markdown@master
74
      - run:
75
          name: Build docs
76
          command: |
77
            cd docs/
78
            mkdir -p theme_dir/img/ipynb/
79
            ./render_ipynb.bash
80
            pydocmd build
81
      - run:
82
          name: Deploy docs
83
          command: .circleci/deploy_docs.bash
84
85
workflows:
86
  version: 2
87
88
  test:
89
    jobs:
90
      - test-py36
91
      # - build-deploy-docs:
92
      #     requires:
93
      #       - test-py36
94
      #     filters:
95
      #       branches:
96
      #         only:
97
      #           - master
98
      #           - test_deployment_script