Skip to content

Commit 6ae9a65

Browse files
committed
Rebuild the recipe without test for upload
1 parent 9c51791 commit 6ae9a65

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

ci/deploy_anaconda.py

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,24 @@
33
import re
44
import conda_build.api
55
import subprocess as spr
6-
fnames = list(conda_build.api.get_output_file_paths(
7-
os.path.join('ci', 'conda-recipe')))
8-
py_patt = re.compile('py\d\d')
9-
repl = 'py' + os.getenv('PYTHON_VERSION').replace('.', '')
10-
fnames = [py_patt.sub(repl, f) for f in fnames]
6+
7+
recipe_path = 'ci/conda-recipe'
8+
119
if os.getenv("TRAVIS") == "true":
1210
branch = os.getenv("TRAVIS_BRANCH")
1311
on_release = os.getenv("TRAVIS_TAG") != ""
1412
else:
1513
branch = os.getenv("APPVEYOR_REPO_BRANCH")
1614
on_release = bool(os.getenv("APPVEYOR_REPO_TAG_NAME"))
17-
label = ['-l', branch] if not on_release else []
18-
token = ['-t', os.getenv('CONDA_REPO_TOKEN')]
1915

20-
print("Uploading via " +
21-
" ".join(['anaconda -t *****', 'upload', '--force'] + label + fnames))
16+
label = ['--label', branch] if not on_release else []
17+
token = ['--token', os.getenv('CONDA_REPO_TOKEN')]
18+
19+
command = ["conda", "build", "--no-test", "--no-copy-test-source-files"]
20+
21+
spr.check_call(["conda", "config", "--set", "anaconda_upload", "yes"])
22+
23+
print("Building recipe via " +
24+
" ".join(command + ["--token *******"] + label + [recipe_path]))
2225

23-
spr.check_call(
24-
['anaconda'] + token + ['upload', '--force'] +
25-
label + fnames
26-
)
26+
spr.check_call(command + token + label + [recipe_path])

0 commit comments

Comments
 (0)