diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5a3a989..fa65e51 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,16 +16,13 @@ jobs: build: runs-on: ubuntu-latest - strategy: - matrix: - python-version: [3.6, 3.7, 3.8] steps: - uses: actions/checkout@v2 - name: Set up Python uses: actions/setup-python@v2 with: - python-version: ${{ matrix.python-version }} + python-version: 3.8 - name: Install dependencies run: | python -m pip install --upgrade pip @@ -33,6 +30,7 @@ jobs: pip install numpy pip install h5py pip install dask + pip install build if [ -f requirements.txt ]; then pip install -r requirements.txt; fi - name: Lint with flake8 run: | @@ -43,3 +41,15 @@ jobs: - name: Test with pytest run: | python3 -m pytest --cov=swmr_tools + - name: Build a binary wheel and a source tarball + run: >- + python -m + build + --sdist + --wheel + --outdir dist/ + - name: publish to TestPyPI + uses: pypa/gh-action-pypi-publish@master + with: + password: ${{ secrets.TEST_PYPI_API_TOKEN }} + repository_url: https://test.pypi.org/legacy/ diff --git a/pyproject.toml b/pyproject.toml new file mode 100644 index 0000000..374b58c --- /dev/null +++ b/pyproject.toml @@ -0,0 +1,6 @@ +[build-system] +requires = [ + "setuptools>=42", + "wheel" +] +build-backend = "setuptools.build_meta"