From 6706ced0ea03ba3adf8ab0f5a7bd6052f8d51488 Mon Sep 17 00:00:00 2001 From: edavalosanaya Date: Sat, 5 Nov 2022 16:26:09 -0500 Subject: [PATCH] Updated version to 0.0.3, fixed some minor links, and added deploy. --- .github/workflows/deploy.yml | 61 ++++++++++++++++++++++++++++++++++++ README.md | 2 +- docs/developer/index.rst | 2 +- docs/index.rst | 8 +++-- setup.cfg | 4 +-- 5 files changed, 70 insertions(+), 7 deletions(-) create mode 100644 .github/workflows/deploy.yml diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 00000000..8b9e2433 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,61 @@ +name: Publish ChimeraPy to PyPI / GitHub + +on: + push: + tags: + - "v*" + +jobs: + build-n-publish: + name: Build and publish to PyPI + runs-on: ubuntu-latest + + steps: + - name: Checkout source + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: "3.9" + + - name: Build source and wheel distributions + run: | + sudo apt-get update + sudo apt-get install ffmpeg libsm6 libxext6 -y + python3 -m pip install --upgrade pip + python -m pip install --upgrade build twine + python -m build + twine check --strict dist/* + - name: Publish distribution to PyPI + uses: pypa/gh-action-pypi-publish@master + with: + user: __token__ + password: ${{ secrets.PYPI_API_TOKEN }} + + - name: Create GitHub Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token + with: + tag_name: ${{ github.ref }} + release_name: ${{ github.ref }} + draft: false + prerelease: false + + - name: Get Asset name + run: | + export PKG=$(ls dist/ | grep tar) + set -- $PKG + echo "name=$1" >> $GITHUB_ENV + - name: Upload Release Asset (sdist) to GitHub + id: upload-release-asset + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + asset_path: dist/${{ env.name }} + asset_name: ${{ env.name }} + asset_content_type: application/zip diff --git a/README.md b/README.md index c9533068..b654fffe 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ ![logo](docs/_static/logo/chimerapy_logo_with_name.png#gh-dark-mode-only) ![logo](docs/_static/logo/chimerapy_logo_with_name_theme_blue.png#gh-light-mode-only) -![PyPI](https://img.shields.io/pypi/v/chimerapy) [![Coverage Status](https://coveralls.io/repos/github/oele-isis-vanderbilt/ChimeraPy/badge.svg?branch=main)](https://coveralls.io/github/oele-isis-vanderbilt/ChimeraPy?branch=main) ![](https://img.shields.io/github/workflow/status/oele-isis-vanderbilt/ChimeraPy/Test) ![](https://img.shields.io/github/license/oele-isis-vanderbilt/ChimeraPy) ![](https://img.shields.io/badge/style-black-black) +[![PyPI](https://img.shields.io/pypi/v/chimerapy)](https://pypi.org/project/chimerapy/) [![Coverage Status](https://coveralls.io/repos/github/oele-isis-vanderbilt/ChimeraPy/badge.svg?branch=main)](https://coveralls.io/github/oele-isis-vanderbilt/ChimeraPy?branch=main) ![](https://img.shields.io/github/workflow/status/oele-isis-vanderbilt/ChimeraPy/Test) ![](https://img.shields.io/github/license/oele-isis-vanderbilt/ChimeraPy) ![](https://img.shields.io/badge/style-black-black) * [Docs](https://oele-isis-vanderbilt.github.io/ChimeraPy) diff --git a/docs/developer/index.rst b/docs/developer/index.rst index 7e0d4467..13adf02b 100644 --- a/docs/developer/index.rst +++ b/docs/developer/index.rst @@ -28,7 +28,7 @@ Below is the developer documentation, which includes all the classes, methods, and modules used by ChimeraPy. .. toctree:: - :maxdepth: 5 + :maxdepth: 2 :includehidden: communication.rst diff --git a/docs/index.rst b/docs/index.rst index c396a8ef..8c8c7516 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -7,13 +7,15 @@ :width: 90% :alt: ChimeraPy Logo -|pipy| |coverage| |test| |license| |style| +|pipy|_ |coverage|_ |test| |license| |style| .. |pipy| image:: https://img.shields.io/pypi/v/chimerapy :alt: PyPI +.. _pipy: https://pypi.org/project/chimerapy/ .. |coverage| image:: https://coveralls.io/repos/github/oele-isis-vanderbilt/ChimeraPy/badge.svg?branch=main :alt: coverage +.. _coverage: https://coveralls.io/github/oele-isis-vanderbilt/ChimeraPy?branch=main .. |test| image:: https://img.shields.io/github/workflow/status/oele-isis-vanderbilt/ChimeraPy/Test :alt: test @@ -52,13 +54,13 @@ Contents framework/index .. toctree:: - :maxdepth: 3 + :maxdepth: 2 :includehidden: api/index .. toctree:: - :maxdepth: 6 + :maxdepth: 3 :includehidden: developer/index diff --git a/setup.cfg b/setup.cfg index 47bd1a4b..ce107afe 100644 --- a/setup.cfg +++ b/setup.cfg @@ -2,14 +2,14 @@ # here: https://packaging.python.org/tutorials/packaging-projects/ [metadata] name = chimerapy -version = 0.0.2 +version = 0.0.3 url = https://github.com/oele-isis-vanderbilt/ChimeraPy description = ChimeraPy: Python Distributed MultiModal Data Framework long_description = file: README.md long_description_content_type = text/markdown license = GNU GENERAL Public License platform = any -keywords = multimodal, data, analysis, real-time, distributed +keywords = multimodal, data, distributed, streaming, real-time classifiers = Programming Language :: Python :: 3 Programming Language :: Python :: 3.6