From d39c569d47a1bb5f34f4e0c37e8766ad29f1b447 Mon Sep 17 00:00:00 2001 From: Kashif Rasul Date: Sun, 5 Jul 2020 11:22:31 +0200 Subject: [PATCH] publish to test-pypi with user token updated url added author only sdist make bdist_wheel fix typo publish to pypi moved to 1 workflow remove test workflow add to test github.event_name run on relase created --- .github/workflows/publish-to-pypi.yml | 36 +++++++++++++++++++++++++++ .gitignore | 3 +++ setup.py | 5 ++-- 3 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/publish-to-pypi.yml diff --git a/.github/workflows/publish-to-pypi.yml b/.github/workflows/publish-to-pypi.yml new file mode 100644 index 0000000..223a5f0 --- /dev/null +++ b/.github/workflows/publish-to-pypi.yml @@ -0,0 +1,36 @@ +name: Publish Python 🐍 distributions 📦 to PyPI and TestPyPI + +on: + release: + types: [created] + +jobs: + build-n-publish: + name: Build and publish Python 🐍 distributions 📦 to PyPI and TestPyPI + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@master + - name: Set up Python 3.x + uses: actions/setup-python@v1 + with: + python-version: '3.x' + - name: Install dependencies + run: >- + python -m + pip install --upgrade + pip setuptools twine + --user + - name: Build a binary wheel and a source tarball + run: >- + python setup.py sdist + - name: Publish distribution 📦 to PyPI + uses: pypa/gh-action-pypi-publish@master + with: + user: __token__ + password: ${{ secrets.pypi_password }} + - name: Publish distribution 📦 to Test PyPI + uses: pypa/gh-action-pypi-publish@master + with: + user: __token__ + password: ${{ secrets.test_pypi_password }} + repository_url: https://test.pypi.org/legacy/ diff --git a/.gitignore b/.gitignore index d14244e..6f18569 100644 --- a/.gitignore +++ b/.gitignore @@ -102,5 +102,8 @@ venv.bak/ # mypy .mypy_cache/ + +# other .idea/ runs/ +.vscode/ diff --git a/setup.py b/setup.py index 6633866..e208e74 100644 --- a/setup.py +++ b/setup.py @@ -6,8 +6,9 @@ setup( description="PyTorch Probabilistic Time Series Modeling framework", long_description=open("README.md").read(), long_description_content_type="text/markdown", - - url='https://github.com/kashif/pytorch-ts', + author='Kashif Rasul', + author_email="kashif.rasul@zalando.de", + url='https://github.com/zalandoresearch/pytorch-ts', license='MIT', packages=find_packages(exclude=["tests"]),