diff --git a/.github/workflows/pypi.yml b/.github/workflows/pypi.yml index 1a0cf02..cd66123 100644 --- a/.github/workflows/pypi.yml +++ b/.github/workflows/pypi.yml @@ -31,10 +31,15 @@ jobs: - name: Install build dependencies run: | python -m pip install --upgrade pip - pip install build + pip install --upgrade setuptools wheel build twine - - name: Build package - run: python -m build + - name: Build and publish + env: + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} + run: | + python -m build + twine upload --repository pypi dist/* - name: Generate SHA256 run: | @@ -50,7 +55,3 @@ jobs: create_release: true env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - - name: Publish to PyPI - uses: pypa/gh-action-pypi-publish@v1.12 diff --git a/pyproject.toml b/pyproject.toml index 4e44d1b..844e345 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -22,20 +22,23 @@ dependencies = [ [project.scripts] fireblocks-cli = "fireblocks_cli.main:app" -[tool.poetry.group.dev.dependencies] -mypy = "^1.15.0" -pyinstaller = "^6.13.0" -black = "^25.1.0" -reuse = { version = "^5.0.2", python = ">=3.9,<4.0" } -pre-commit = "^4.2.0" -build = "^1.2.2.post1" -twine = "^6.1.0" -pytest = "^8.3.5" -types-toml = "^0.10.8.20240310" +[project.optional-dependencies] +dev = [ + "mypy>=1.15.0", + "pyinstaller>=6.13.0", + "black>=25.1.0", + "reuse>=5.0.2; python_version >= '3.9' and python_version < '4.0'", + "pre-commit>=4.2.0", + "build>=1.2.2.post1", + "twine>=6.1.0", + "pytest>=8.3.5", + "types-toml>=0.10.8.20240310" +] [build-system] -requires = ["setuptools>=65", "wheel"] +requires = ["setuptools>=68", "wheel"] build-backend = "setuptools.build_meta" [tool.setuptools.packages.find] +where = ["."] include = ["fireblocks_cli*"]