Skip to content

Commit

Permalink
Merge aded8b8 into 52afc80
Browse files Browse the repository at this point in the history
  • Loading branch information
beckermr committed Jun 1, 2020
2 parents 52afc80 + aded8b8 commit 0579666
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 5 deletions.
4 changes: 3 additions & 1 deletion conda_smithy/templates/appveyor.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,12 @@ build: off
test_script:
- cmd: conda.exe build {{ recipe_dir }} -m .ci_support\%CONFIG%.yaml
{%- if conda_forge_output_validation %}
- cmd: validate_recipe_outputs "{{ feedstock_name }}"
- set "FEEDSTOCK_NAME=%APPVEYOR_REPO_NAME:*/=%"
- cmd: validate_recipe_outputs "%FEEDSTOCK_NAME%"
{%- endif %}
deploy_script:
- set "GIT_BRANCH=%APPVEYOR_REPO_BRANCH%"
- set "FEEDSTOCK_NAME=%APPVEYOR_REPO_NAME:*/=%"
{%- if upload_on_branch %}
- set "UPLOAD_ON_BRANCH={{ upload_on_branch }}"
{%- endif %}
Expand Down
1 change: 1 addition & 0 deletions conda_smithy/templates/azure-pipelines-linux.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ jobs:
- script: |
export CI=azure
export GIT_BRANCH=$BUILD_SOURCEBRANCHNAME
export FEEDSTOCK_NAME=`basename ${BUILD_REPOSITORY_NAME}`
{%- if upload_on_branch %}
export UPLOAD_ON_BRANCH="{{ upload_on_branch }}"
{%- endif %}
Expand Down
1 change: 1 addition & 0 deletions conda_smithy/templates/azure-pipelines-osx.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
export CI=azure
export OSX_FORCE_SDK_DOWNLOAD="1"
export GIT_BRANCH=$BUILD_SOURCEBRANCHNAME
export FEEDSTOCK_NAME=`basename ${BUILD_REPOSITORY_NAME}`
{%- if upload_on_branch %}
export UPLOAD_ON_BRANCH="{{ upload_on_branch }}"
{%- endif %}
Expand Down
4 changes: 3 additions & 1 deletion conda_smithy/templates/azure-pipelines-win.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,15 @@ jobs:
{%- if conda_forge_output_validation %}
- script: |
set "FEEDSTOCK_NAME=%BUILD_REPOSITORY_NAME:*/=%"
call activate base
validate_recipe_outputs "{{ feedstock_name }}"
validate_recipe_outputs "%FEEDSTOCK_NAME%"
displayName: Validate Recipe Outputs
{%- endif %}

- script: |
set "GIT_BRANCH=%BUILD_SOURCEBRANCHNAME%"
set "FEEDSTOCK_NAME=%BUILD_REPOSITORY_NAME:*/=%"
{%- if upload_on_branch %}
set "UPLOAD_ON_BRANCH={{ upload_on_branch }}"
{%- endif %}
Expand Down
2 changes: 1 addition & 1 deletion conda_smithy/templates/build_steps.sh.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ conda build "${RECIPE_ROOT}" -m "${CI_SUPPORT}/${CONFIG}.yaml" \
--clobber-file "${CI_SUPPORT}/clobber_${CONFIG}.yaml"

{%- if conda_forge_output_validation %}
validate_recipe_outputs "{{ feedstock_name }}"
validate_recipe_outputs "${FEEDSTOCK_NAME}"
{%- endif %}

if [[ "${UPLOAD_PACKAGES}" != "False" ]]; then
Expand Down
2 changes: 2 additions & 0 deletions conda_smithy/templates/circle.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ jobs:
{%- if data.platform.startswith('linux') %}
command: |
export CI=circle
export FEEDSTOCK_NAME=`basename ${CIRCLE_PROJECT_REPONAME}`
./.scripts/run_docker_build.sh
{%- else %}
command: |
export CI=circle
export FEEDSTOCK_NAME=`basename ${CIRCLE_PROJECT_REPONAME}`
./.scripts/run_osx_build.sh
{%- endif %}
{%- if idle_timeout_minutes %}
Expand Down
1 change: 1 addition & 0 deletions conda_smithy/templates/drone.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ steps:
- export RECIPE_ROOT="$FEEDSTOCK_ROOT/{{ recipe_dir }}"
- export CI=drone
- export GIT_BRANCH="$DRONE_BRANCH"
- export FEEDSTOCK_NAME=`basename ${DRONE_REPO_NAME}`
{%- if upload_on_branch %}
- export UPLOAD_ON_BRANCH="{{ upload_on_branch }}"
{%- endif %}
Expand Down
5 changes: 5 additions & 0 deletions conda_smithy/templates/run_docker_build.sh.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ PROVIDER_DIR="$(basename $THISDIR)"
FEEDSTOCK_ROOT=$(cd "$(dirname "$0")/.."; pwd;)
RECIPE_ROOT="${FEEDSTOCK_ROOT}/{{ recipe_dir }}"

if [ -z ${FEEDSTOCK_NAME} ]; then
export FEEDSTOCK_NAME=`basename ${FEEDSTOCK_ROOT}`
fi

docker info

# In order for the conda-build process in the container to write to the mounted
Expand Down Expand Up @@ -70,6 +74,7 @@ export UPLOAD_PACKAGES="${UPLOAD_PACKAGES:-True}"
-e UPLOAD_ON_BRANCH \
-e CI \
{%- if conda_forge_output_validation %}
-e FEEDSTOCK_NAME \
-e FEEDSTOCK_TOKEN \
-e STAGING_BINSTAR_TOKEN \
{%- endif %}
Expand Down
2 changes: 1 addition & 1 deletion conda_smithy/templates/run_osx_build.sh.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ make_build_number ./ ./{{ recipe_dir }} ./.ci_support/${CONFIG}.yaml
conda build ./{{ recipe_dir }} -m ./.ci_support/${CONFIG}.yaml --clobber-file ./.ci_support/clobber_${CONFIG}.yaml

{%- if conda_forge_output_validation %}
validate_recipe_outputs "{{ feedstock_name }}"
validate_recipe_outputs "${FEEDSTOCK_NAME}"
{%- endif %}

if [[ "${UPLOAD_PACKAGES}" != "False" ]]; then
Expand Down
1 change: 1 addition & 0 deletions conda_smithy/templates/travis.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ matrix:
script:
- export CI=travis
- export GIT_BRANCH="$TRAVIS_BRANCH"
- export FEEDSTOCK_NAME=`basename ${TRAVIS_REPO_SLUG}`
{%- if upload_on_branch %}
- export UPLOAD_ON_BRANCH="{{ upload_on_branch }}"
{%- endif %}
Expand Down
2 changes: 1 addition & 1 deletion tests/test_configure_feedstock.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def test_upload_on_branch_appveyor(upload_on_branch_recipe, jinja_env):
) as fp:
content = yaml.load(fp)
assert "%APPVEYOR_REPO_BRANCH%" in content["deploy_script"][0]
assert "UPLOAD_ON_BRANCH=foo-branch" in content["deploy_script"][1]
assert "UPLOAD_ON_BRANCH=foo-branch" in content["deploy_script"][-2]


def test_circle_with_yum_reqs(py_recipe, jinja_env):
Expand Down

0 comments on commit 0579666

Please sign in to comment.