Skip to content

Commit 229d54f

Browse files
committed
Add jobs for deploying and installing
1 parent 796eb02 commit 229d54f

File tree

1 file changed

+32
-5
lines changed

1 file changed

+32
-5
lines changed

.circleci/config.yml

Lines changed: 32 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,8 @@ jobs:
117117
echo "Uploading to test.pypi.org"
118118
./venv/bin/twine upload --repository-url https://test.pypi.org/legacy/ workspace/dist/*`cat workspace/version.txt`*
119119
120-
install_test_pypi:
121-
# Try to install from test-pip
120+
install_from_test_pypi:
121+
# Try to install from test-pypi
122122
docker:
123123
- image: circleci/python:3.6
124124

@@ -140,6 +140,29 @@ jobs:
140140
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple flask-log-request-id==`cat workspace/version.txt`
141141
pip freeze | grep -i flask-log-request-id
142142
143+
install_from_pypi:
144+
# Try to install from public pypi
145+
docker:
146+
- image: circleci/python:3.6
147+
148+
steps:
149+
- attach_workspace:
150+
at: workspace
151+
152+
- run:
153+
name: Create virtual-environment
154+
command: |
155+
python3 -m venv venv
156+
. venv/bin/activate
157+
158+
- run:
159+
name: Install from pip
160+
# Try to install the same version from PyPI
161+
command: |
162+
. venv/bin/activate
163+
pip install flask-log-request-id==`cat workspace/version.txt`
164+
pip freeze | grep -i flask-log-request-id
165+
143166
workflows:
144167
version: 2
145168
test_build_deploy:
@@ -158,11 +181,11 @@ workflows:
158181
- staging
159182
requires:
160183
- build
161-
- install_test_pypi:
184+
185+
- install_from_test_pypi:
162186
requires:
163187
- deploy_test_pypi
164188

165-
166189
- request_permission_for_public_pypi:
167190
type: approval
168191
requires:
@@ -176,4 +199,8 @@ workflows:
176199

177200
- deploy_pypi:
178201
requires:
179-
- request_permission_for_public_pypi
202+
- request_permission_for_public_pypi
203+
204+
- install_from_pypi:
205+
requires:
206+
- deploy_pypi

0 commit comments

Comments
 (0)