diff --git a/.github/workflows/ci_pipeline.yml b/.github/workflows/ci_pipeline.yml index eac2f16..6c222e7 100644 --- a/.github/workflows/ci_pipeline.yml +++ b/.github/workflows/ci_pipeline.yml @@ -30,10 +30,6 @@ jobs: python -m pip install --upgrade pip pip install ".[dev]" - - name: Inspect maxplotlib arguments - run: | - maxplotlib -h - - name: Run tests run: | coverage run -m pytest . diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..eaff1cd --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,34 @@ +name: Publish Python Package + +on: + push: + branches: + - main + +jobs: + build-and-publish: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Set up Python + uses: actions/setup-python@v4 + with: + python-version: "3.10" + + - name: Install build tools + run: | + python -m pip install --upgrade pip + pip install build twine + + - name: Build the package + run: python -m build + + - name: Publish to PyPI + env: + TWINE_USERNAME: __token__ # Use API token + TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }} + run: twine upload dist/* + diff --git a/pyproject.toml b/pyproject.toml index 49b4073..b1b25c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,6 +47,3 @@ dev = [ [tool.setuptools.packages.find] where = ["src"] - -[project.scripts] -maxplotlib = "maxplotlib.console.main:maxplotlib" diff --git a/src/maxplotlib/console/main.py b/src/maxplotlib/console/main.py deleted file mode 100644 index f31d089..0000000 --- a/src/maxplotlib/console/main.py +++ /dev/null @@ -1,2 +0,0 @@ -def maxplotlib(): - print("Hello, world!")