From f1234e354f2364b15f7f8e97d96887db79bda189 Mon Sep 17 00:00:00 2001 From: Hauke Schulz <43613877+observingClouds@users.noreply.github.com> Date: Fri, 5 Aug 2022 16:55:18 -0700 Subject: [PATCH 1/3] add ci job for package upload to pypi --- .github/workflows/pypi.yaml | 51 +++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/pypi.yaml diff --git a/.github/workflows/pypi.yaml b/.github/workflows/pypi.yaml new file mode 100644 index 0000000..f367060 --- /dev/null +++ b/.github/workflows/pypi.yaml @@ -0,0 +1,51 @@ +name: Publish to PyPI + +on: + pull_request: + push: + branches: + - main + release: + types: + - published + +jobs: + packages: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + + - name: Set up Python + uses: actions/setup-python@v3 + with: + python-version: "3.x" + + - name: Get tags + run: git fetch --depth=1 origin +refs/tags/*:refs/tags/* + shell: bash + + - name: Install build tools + run: | + python -m pip install --upgrade pip wheel setuptools setuptools_scm build twine + shell: bash + + - name: Build binary wheel + run: python -m build --sdist --wheel . --outdir dist + + - name: CheckFiles + run: | + ls dist + shell: bash + + - name: Test wheels + run: | + cd dist && python -m pip install pysonde*.whl + python -m twine check * + shell: bash + + - name: Publish a Python distribution to PyPI + if: success() && github.event_name == 'release' + uses: pypa/gh-action-pypi-publish@release/v1 + with: + user: __token__ + password: ${{ secrets.PYPI_PASSWORD }} From 37d907f5b2df88e4a02395a1008cbf96e84ba466 Mon Sep 17 00:00:00 2001 From: Hauke Schulz <43613877+observingClouds@users.noreply.github.com> Date: Fri, 2 Sep 2022 17:08:43 -0700 Subject: [PATCH 2/3] Fix long_description --- setup.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/setup.py b/setup.py index 04980e6..1b22bac 100644 --- a/setup.py +++ b/setup.py @@ -20,9 +20,6 @@ "pytest-yapf3>=0.4.0", ] -with open("README.md", "r") as fh: - long_description = fh.read() - setup( # Metadata name="pysonde", @@ -31,6 +28,7 @@ author="Hauke Schulz", author_email="", url="https://github.com/observingClouds/pysonde", + long_description = "Post-processing tool for atmospheric sounding data", # Package modules and data packages=find_packages(), # Requires From 24c4ad947f53cabe2b53100f99a09373c9c4bb18 Mon Sep 17 00:00:00 2001 From: Hauke Schulz <43613877+observingClouds@users.noreply.github.com> Date: Fri, 2 Sep 2022 17:17:57 -0700 Subject: [PATCH 3/3] black reformatting --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 1b22bac..f2d4ea6 100644 --- a/setup.py +++ b/setup.py @@ -28,7 +28,7 @@ author="Hauke Schulz", author_email="", url="https://github.com/observingClouds/pysonde", - long_description = "Post-processing tool for atmospheric sounding data", + long_description="Post-processing tool for atmospheric sounding data", # Package modules and data packages=find_packages(), # Requires