diff --git a/.circleci/config.yml b/.circleci/config.yml index 94af0a31..ec08afb9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -21,10 +21,15 @@ jobs: type: string steps: - checkout - - run: pip install --user --upgrade setuptools twine wheel - - run: | - python setup.py sdist bdist_wheel - twine upload --repository-url <> --username <> --password <> --verbose dist/* + - when: + condition: + equal: [ master, << pipeline.git.branch >> ] + steps: + - run: pip install --user --upgrade setuptools twine wheel + - run: | + "$CIRCLE_BRANCH" == "master" && echo "Publishing to PyPI" || echo "Publishing to Cloudsmith" + python setup.py sdist bdist_wheel + twine upload --repository-url <> --username <> --password <> --verbose dist/* orbs: python: circleci/python@2.1.1