Skip to content

Commit 5125333

Browse files
committed
Build the package and publish on master.
1 parent 79856b5 commit 5125333

File tree

2 files changed

+13
-44
lines changed

2 files changed

+13
-44
lines changed

.github/workflows/main.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
name: testcontainers-python
22
on:
33
push:
4-
branches: [ master ]
4+
branches: [master]
55
pull_request:
6-
branches: [ master ]
6+
branches: [master]
77

88
jobs:
99
sphinx:
@@ -108,3 +108,14 @@ jobs:
108108
run: >
109109
pytest -svx --cov-report=term-missing --cov=testcontainers.${{ matrix.test-component }}
110110
--tb=short ${{ matrix.test-component }}/tests
111+
- name: Build the package
112+
working-directory: ${{ matrix.test-component }}
113+
run: |
114+
python setup.py bdist_wheel
115+
twine check dist/*
116+
- name: Publish the package to pypi
117+
if: github.event_name == 'push' && github.ref == 'refs/heads/master' && github.repository_owner == 'testcontainers'
118+
env:
119+
TWINE_USERNAME: __token__
120+
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
121+
run: twine upload ${{ matrix.test-component }}/dist/*

.github/workflows/pypi-release.yml

Lines changed: 0 additions & 42 deletions
This file was deleted.

0 commit comments

Comments
 (0)