forked from jpn--/larch
-
Notifications
You must be signed in to change notification settings - Fork 0
/
azure-pipelines.yml
108 lines (92 loc) · 3.04 KB
/
azure-pipelines.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
trigger:
- master
- develop
jobs:
- job:
displayName: ubuntu-latest
pool:
vmImage: 'ubuntu-latest'
strategy:
matrix:
Python39:
python.version: '3.9'
# Python310:
# python.version: '3.10'
steps:
- bash: echo "##vso[task.prependpath]$CONDA/bin"
displayName: Add conda to PATH
# Install mamba to manage dependencies faster
- bash: conda install --yes mamba -c conda-forge
displayName: Install Mamba package manager
- bash: mamba create --yes --quiet --name larch-build-environment "python=$PYTHON_VERSION" -c conda-forge -c nodefaults
displayName: Create conda environment
- bash: |
source activate larch-build-environment
mamba install --yes --quiet --name larch-build-environment numpy conda-build anaconda-client cython conda-verify pytest pytest-azurepipelines boa -c conda-forge
displayName: Install basic conda packages
- bash: |
source activate larch-build-environment
mkdir ~/conda-bld
conda config --set anaconda_upload no
export CONDA_BLD_PATH=~/conda-bld
conda mambabuild conda-recipe -c conda-forge -c nodefaults
displayName: Conda Build with mambabuild
# - job:
# displayName: macOS-10.13
# pool:
# vmImage: 'macOS-10.13'
# strategy:
# matrix:
# Python27:
# python.version: '2.7'
# Python36:
# python.version: '3.6'
# steps:
# - bash: echo "##vso[task.prependpath]$CONDA/bin"
# displayName: Add conda to PATH
# - bash: conda create --yes --quiet --name myEnvironment
# displayName: Create Anaconda environment
# - bash: |
# source activate myEnvironment
# conda install --yes --quiet --name myEnvironment python=$PYTHON_VERSION numpy
# pip install pytest pytest-azurepipelines
# displayName: Install Anaconda packages
# - bash: |
# source activate myEnvironment
# pytest
# displayName: pytest
- job:
displayName: windows-latest
pool:
vmImage: 'windows-latest'
strategy:
matrix:
Python39:
python.version: '3.9'
# Python310:
# python.version: '3.10'
variables:
CONDA_BLD_PATH: D:\\bld\\
steps:
- powershell: Write-Host "##vso[task.prependpath]$env:CONDA\Scripts"
displayName: Add conda to PATH
# Install mamba to manage dependencies faster
- script: conda install --yes mamba -c conda-forge
displayName: Install Mamba package manager
- script: |
conda update -n base -c defaults conda
conda create --yes --quiet --name myEnvironment python=%PYTHON_VERSION% numpy conda-build anaconda-client cython conda-verify pytest pytest-azurepipelines boa -c conda-forge
displayName: Create Anaconda environment
- script: |
call activate myEnvironment
echo "### conda info ###"
conda info
echo "### conda list ###"
conda list
echo "### conda config ###"
conda config --show
displayName: Report Anaconda packages
- script: |
call activate myEnvironment
conda mambabuild conda-recipe -c conda-forge -c nodefaults
displayName: Conda build