From 37e13043dc9a8cc36a158e4c64d1b550bea7e120 Mon Sep 17 00:00:00 2001 From: codematrixer Date: Thu, 5 Sep 2024 12:14:29 +0800 Subject: [PATCH] build: github action pipeline --- .github/workflows/release.yml | 31 +++++++++++++++++++++++++++++++ pyproject.toml | 5 ++++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..b3d1265 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,31 @@ +name: Release + +on: + release: + types: [created] + +jobs: + build-n-publish: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install setuptools wheel twine poetry + poetry install + + - name: Build a binary wheel and a source tarball + run: poetry build + + - name: Publish distribution 📦 to PyPI + uses: pypa/gh-action-pypi-publish@release/v1 + with: + password: ${{ secrets.PYPI_API_TOKEN }} + packages-dir: dist \ No newline at end of file diff --git a/pyproject.toml b/pyproject.toml index 2ad274e..ec1c141 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,8 +1,11 @@ [tool.poetry] name = "hmdriver2" -version = "1.0.1" +version = "1.0.0" description = "UI Automation Framework for Harmony Next" authors = ["codematrixer "] +license = "MIT" +readme = "README.md" +include = ["*/asset/*"] [tool.poetry.dependencies] python = "^3.8"