diff --git a/conda_smithy/cli.py b/conda_smithy/cli.py index e0db2b1e0..9dc2abc8c 100755 --- a/conda_smithy/cli.py +++ b/conda_smithy/cli.py @@ -88,13 +88,6 @@ def __call__(self, args): "conda-recipe you want to build a feedstock for. Got {}".format( args.recipe_directory)) - # conda-build has some really fruity behaviour where it needs CONDA_NPY - # and CONDA_PY in order to even read a meta. Because we compute version - # matricies anyway the actual number makes absolutely no difference. - import conda_build.config - conda_build.metadata.config.CONDA_NPY = '99.9' - conda_build.metadata.config.CONDA_PY = 10 - # Get some information about the source recipe. if args.recipe_directory: meta = MetaData(args.recipe_directory) diff --git a/conda_smithy/configure_feedstock.py b/conda_smithy/configure_feedstock.py index 1ce00402b..c2a39c79a 100755 --- a/conda_smithy/configure_feedstock.py +++ b/conda_smithy/configure_feedstock.py @@ -194,6 +194,14 @@ def main(forge_file_directory): tmplt_dir])) copy_feedstock_content(forge_dir) + + # conda-build has some really fruity behaviour where it needs CONDA_NPY + # and CONDA_PY in order to even read a meta. Because we compute version + # matricies anyway the actual number makes absolutely no difference. + import conda_build.config + conda_build.metadata.config.CONDA_NPY = '99.9' + conda_build.metadata.config.CONDA_PY = 10 + render_run_docker_build(env, config, forge_dir) render_travis(env, config, forge_dir) render_appveyor(env, config, forge_dir) diff --git a/conda_smithy/templates/travis.yml.tmpl b/conda_smithy/templates/travis.yml.tmpl index b8073fbc4..ba95c1292 100644 --- a/conda_smithy/templates/travis.yml.tmpl +++ b/conda_smithy/templates/travis.yml.tmpl @@ -1,7 +1,7 @@ {%- set conda_vars = {'python': 'CONDA_PY', 'numpy': 'CONDA_NPY'} -%} {% macro matrix_env(matrix_item) -%} {% for dep_name, version in matrix_item | sort %}{%- if dep_name in conda_vars %}{% set version = version|replace('.', '') %}{% endif -%} - {{ conda_vars.get(dep_name, 'CONDA_' + dep_name|upper) }}={{ version }} {% endfor %} + {{ conda_vars.get(dep_name, 'CONDA_' + dep_name|upper) }}={{ version }}{% if not loop.last %} {% endif %}{% endfor %} {%- endmacro %} # This file was generated automatically from conda-smithy. To update this configuration, # update the conda-forge.yaml and/or the recipe/meta.yaml.