Skip to content
This repository was archived by the owner on Feb 14, 2023. It is now read-only.

Commit 5c6b077

Browse files
committed
Merge remote-tracking branch 'upstream/master' into sdist_build
2 parents c6e7e71 + 8859f4f commit 5c6b077

File tree

2 files changed

+22
-28
lines changed

2 files changed

+22
-28
lines changed

azure/posix.yml

+12-15
Original file line numberDiff line numberDiff line change
@@ -98,16 +98,6 @@ jobs:
9898
displayName: 'Publish Test Results'
9999
condition: eq(variables['SKIP_BUILD'], 'false')
100100

101-
- bash: |
102-
echo "##vso[task.prependpath]$CONDA/bin"
103-
sudo chown -R $USER $CONDA
104-
displayName: Add conda to PATH
105-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
106-
107-
- bash: conda install -q -y anaconda-client
108-
displayName: Install anaconda-client
109-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
110-
111101
- bash: |
112102
set -e
113103
if [ "$BUILD_REASON" == "Schedule" ]; then
@@ -117,18 +107,25 @@ jobs:
117107
ANACONDA_ORG="scikit-learn-wheels-staging"
118108
TOKEN="$SCIKIT_LEARN_STAGING_UPLOAD_TOKEN"
119109
fi
120-
if [ "$TOKEN" == "" ]; then
121-
echo "##[warning] Could not find anaconda.org upload token in secret variables"
122-
fi
123110
echo "##vso[task.setvariable variable=TOKEN]$TOKEN"
124111
echo "##vso[task.setvariable variable=ANACONDA_ORG]$ANACONDA_ORG"
125112
displayName: Retrieve secret upload token
126-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
113+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN'], variables['SCIKIT_LEARN_STAGING_UPLOAD_TOKEN'])
127114
env:
128115
# Secret variables need to mapped to env variables explicitly:
129116
SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN: $(SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN)
130117
SCIKIT_LEARN_STAGING_UPLOAD_TOKEN: $(SCIKIT_LEARN_STAGING_UPLOAD_TOKEN)
131118
119+
- bash: |
120+
echo "##vso[task.prependpath]$CONDA/bin"
121+
sudo chown -R $USER $CONDA
122+
displayName: Add conda to PATH
123+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['TOKEN'])
124+
125+
- bash: conda install -q -y anaconda-client
126+
displayName: Install anaconda-client
127+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['TOKEN'])
128+
132129
- bash: |
133130
set -e
134131
# The --force option forces a replacement if the remote file already
@@ -137,4 +134,4 @@ jobs:
137134
anaconda -t $TOKEN upload --force -u $ANACONDA_ORG wheelhouse/*.whl
138135
echo "PyPI-style index: https://pypi.anaconda.org/$ANACONDA_ORG/simple"
139136
displayName: Upload to anaconda.org (only if secret token is retrieved)
140-
condition: ne(variables['TOKEN'], '')
137+
condition: variables['TOKEN']

azure/windows.yml

+10-13
Original file line numberDiff line numberDiff line change
@@ -107,14 +107,6 @@ jobs:
107107
displayName: 'Publish Test Results'
108108
condition: eq(variables['SKIP_BUILD'], 'false')
109109

110-
- bash: echo "##vso[task.prependpath]$CONDA/Scripts"
111-
displayName: Add conda to PATH
112-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
113-
114-
- bash: conda install -q -y anaconda-client
115-
displayName: Install anaconda-client
116-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
117-
118110
- bash: |
119111
set -e
120112
if [ "$BUILD_REASON" == "Schedule" ]; then
@@ -124,18 +116,23 @@ jobs:
124116
ANACONDA_ORG="scikit-learn-wheels-staging"
125117
TOKEN="$SCIKIT_LEARN_STAGING_UPLOAD_TOKEN"
126118
fi
127-
if [ "$TOKEN" == "" ]; then
128-
echo "##[warning] Could not find anaconda.org upload token in secret variables"
129-
fi
130119
echo "##vso[task.setvariable variable=TOKEN]$TOKEN"
131120
echo "##vso[task.setvariable variable=ANACONDA_ORG]$ANACONDA_ORG"
132121
displayName: Retrieve secret upload token
133-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
122+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN'], variables['SCIKIT_LEARN_STAGING_UPLOAD_TOKEN'])
134123
env:
135124
# Secret variables need to mapped to env variables explicitly:
136125
SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN: $(SCIKIT_LEARN_NIGHTLY_UPLOAD_TOKEN)
137126
SCIKIT_LEARN_STAGING_UPLOAD_TOKEN: $(SCIKIT_LEARN_STAGING_UPLOAD_TOKEN)
138127
128+
- bash: echo "##vso[task.prependpath]$CONDA/Scripts"
129+
displayName: Add conda to PATH
130+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['TOKEN'])
131+
132+
- bash: conda install -q -y anaconda-client
133+
displayName: Install anaconda-client
134+
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'), variables['TOKEN'])
135+
139136
- bash: |
140137
set -e
141138
# The --force option forces a replacement if the remote file already
@@ -144,4 +141,4 @@ jobs:
144141
anaconda -t $TOKEN upload --force -u $ANACONDA_ORG scikit-learn/dist/scikit_learn-*.whl
145142
echo "PyPI-style index: https://pypi.anaconda.org/$ANACONDA_ORG/simple"
146143
displayName: Upload to anaconda.org (only if secret token is retrieved)
147-
condition: ne(variables['TOKEN'], '')
144+
condition: variables['TOKEN']

0 commit comments

Comments
 (0)